[ Web Proxy ]
URL:
Viewing: https://raw.githubusercontent.com/dwipam/code/master/Algorithm/LCS.java [Back]  [Original]

import java.util.Scanner;

public class LCS {
    
    public static void main(String[] args) {
    	Scanner in=new Scanner(System.in);
        int i,j;
        
        System.out.print("Enter the first String  : ");
        String X = in.next();
         
        System.out.print("Enter the Second String : ");
        String Y = in.next();
        int p = X.length();
        int q = Y.length();
        
        int[][] cache = new int[p+1][q+1];
        int[][] direction= new int[p+1][q+1];
	
        
        for (i = 0; i 

Web Proxy Viewer  |  New URL  |  Original Page