HOME         WALKINS         CORE JOBS          GOVT JOBS          TESTING JOBS          BPO JOBS amity niit hp idea nokia religare samsung max_new_york_life naukri

Sunday, March 7, 2010

Dynamic Programming

1)Determine an LCS of {1,0,0,1,0,1,0,1} and {0,1,0,1,1,0,1,1,0}.
2)Give an algorithm to find the Longest common subsequence of sequences with lengths m,n respectively and also analyze their time complexities.
3)Give an algorithm to find the Longest common string of strings with lengths m,n respectively and also analyse their time complexities.
4)Give an O(n^2) time algorithm to find the longest monotonically increasing subsequence of a sequence of n numbers.
5)Give an O(n^2) time algorithm to find the longest monotonically increasing subsequence of a sequence of n numbers.
6)What is the difference between longest common subsequence and longest common substring
7)State few applications of Dynamic Programming.

1 comment:

  1. Hi There,


    A really interesting, clear and easily readable A-->Z interview questions article of interesting and different perspectives' will clap. So much is so well covered here.


    Using C Prog, Dev a prog that will play a number guessing game.The prog should allow users to enter their 3 numbers (between 0-9). You must store teh 3 numbers in a 1D array.

    You prog should use functions. The prog should display a simple menu to the user and each option in teh menu will be implemented by calling a separate function. You must use pointer notation to access array elements-NOT subscripts.
    1. Enter 3 selected numbers
    2. Display the contents of the 1D array containing the numbers you entered.
    3. Compare your chosen lotto numbers in teh 1D array with eh following winning numbers: 1,3, 5
    Return to the main() function how many numbers the use entered correctly and display this.
    4. Reverse the contents of the 1D array containing the numbers the user entered correctly and display this.


    Thanks a lot. This was a perfect step-by-step guide. Don’t think it could have been done better.


    Kind Regards,
    Laura

    ReplyDelete