Re: [algogeeks] Spoj Problem : String based

2011-03-13 Thread Logic King
U didn't understand my problem.i have the problem with this line -- "The length of the needle is only limited by the memory available to your program, so do not make any assumptions - instead, read the length and allocate memory as needed." On Sun, Mar 13, 2011 at 4:00 PM, sukhmeet singh wrot

Re: [algogeeks] Spoj Problem : String based

2011-03-13 Thread sukhmeet singh
in order to deal with such situations u have to read the input till the end of file if your algo is correct then using EOF something like while(scanf("%d",&n)!=EOF) will give u AC..!! On Sun, Mar 13, 2011 at 2:01 PM, Logic King wrote: > I tried the problem https://www.spoj.pl/problems/NHAY/ > > I

[algogeeks] Spoj Problem : String based

2011-03-13 Thread Logic King
I tried the problem https://www.spoj.pl/problems/NHAY/ I didn't Understand the Input of the problem -- The length of the needle is only limited by the memory available to your program, so do not make any assumptions - instead, read the length and allocate memory as needed. The haystack is *not* li