Search Results

Search found 2 results on 1 pages for 'esotericme'.

Page 1/1 | 1 

  • Dynamic Programming resources in C?

    - by EsotericMe
    Hi everyone, I'll be writing the online Google test tomorrow as a fresher. Apparently, they definitely ask one problem on Dynamic Programming? Does anyone know of a good resource for collection of DP problems in C along with solutions? I know what DP is & have used it on an occasion or twice. However I feel to crack a DP problem in test, prior practice of typical problems will make it easier to approach. Any good resources or problem sets with solutions in C will be highly appreciated. Thanks.

    Read the article

  • Finding if a string is an iterative substring?

    - by EsotericMe
    I have a string S. How can I find if the string follows S = nT. Examples: Function should return true if 1) S = "abab" 2) S = "abcdabcd" 3) S = "abcabcabc" 4) S = "zzxzzxzzx" But if S="abcb" returns false. I though maybe we can repeatedly call KMP on substrings of S and then decide. eg: for "abab": call on KMP on "a". it returns 2(two instances). now 2*len("a")!=len(s) call on KMP on "ab". it returns 2. now 2*len("ab")==len(s) so return true Can you suggest any better algorithms?

    Read the article

1