in reply to Re^11: list of unique strings, also eliminating matching substrings
in thread list of unique strings, also eliminating matching substrings
It's simple your version's performance is proportional to the input size, mine is proportional to output.
In rare cases where there are almost no strings to be excluded - i.e. output nearly input - my version can be slightly slower.
In other words if only 10% of all sequences remain after filtering, my algo is about 10 times faster.
BTW: using "\n" instead of chr(0) was a stupid idea, the extra byte is expensive.
Cheers Rolf
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^13: list of unique strings, also eliminating matching substrings
by BrowserUk (Patriarch) on Jun 03, 2011 at 15:20 UTC | |
by LanX (Saint) on Jun 03, 2011 at 15:25 UTC | |
by BrowserUk (Patriarch) on Jun 03, 2011 at 15:53 UTC | |
by LanX (Saint) on Jun 03, 2011 at 16:05 UTC | |
by BrowserUk (Patriarch) on Jun 03, 2011 at 16:31 UTC | |
|