Delete comment from: Andrei Paraschiv's Technical Blog
Hi,
Sorry about that. It's the syntax highlighter messing up the code.
Anyway this is the proper code for line 74:
if ((matches == 0) || (curNode == _root) ||
((matches > 0) && (matches < wordPart.Length) && (matches >= curNode.Label.Length)))
and this one for 101:
//go throught the two streams
for (int i = 0; i < minLength; i++)
{
//if two characters at the same position have the same value we have one more match
if(word[i] == curNode.Label[i])
matches++;
else
//if at any position the two strings have different characters break the cycle
break;
}
//and return the current number of matches
return matches;
}
If anyone can suggest a better syntax highlighter please do so. This one has lots of bugs.
I promise I'll upload all these codes to github or something like that as soon as I find the time.
Apr 18, 2012, 4:14:17 PM
Posted to Radix tree implementation in C#

