Click here to Skip to main content
15,905,504 members

Comments by Member 10018000 (Top 1 by date)

Member 10018000 29-Apr-13 13:29pm View    
Thanks for your quick reply, but my question is not anewered properly. The link you give have the following code, which is not in my understanding.... could you please implement in c#:

function RabinKarp(string s[1..n], string sub[1..m])
hsub := hash(sub[1..m]); hs := hash(s[1..m])
for i from 1 to n-m+1
if hs = hsub
if s[i..i+m-1] = sub
return i
hs := hash(s[i+1..i+m])
return not found