Re: VB6: Best way to find all permutations of a given string in a file - Contest
Yes, I will post the result and code modules for proper viewing and inspection and possible raves...;)
Re: VB6: Best way to find all permutations of a given string in a file - Contest
Quote:
Originally Posted by randem
Aloha,
File must be read and processed in 64kb chunks to allow any size file to be scanned.[/B]
Permutation Variations:
Variable length.
Fixed length.
No repeating characters.
Repeating characters.
This makes no sense. Are you saying that "a" and "ss" are permissible permutations? And why 64K? That is a nonsensical requirement in today's computers. VB6 will 2^31 char in a string. Even if you want the coder to prove they can handle buffers, 64K is a bit silly.
Re: VB6: Best way to find all permutations of a given string in a file - Contest
It makes plenty sense. The requirement are the requirement. Because you may not understand the requirement doesn't mean they don't make sense (the world is larger than just you).
The fact that you ask about "a" and "ss" being permutations is speculatory. Since all the other posts seem to get it. Does that click the light on? Please re-read the posts starting at the beginning. It's all there, even examples...
2 Attachment(s)
Re: VB6: Best way to find all permutations of a given string in a file - Contest
Ok, Here it is. I have been a little busy lately.
Here are the results that you can see for yourselves. Included in the zip file (PermFuncBench.zip) is the following:
1 - File that will create a permutation file to run against the benchmark program.
2 - The benchmark program.
The code for each WORKING entry is in the zip file named BenchMark.zip
Sorry, for the delay...
.
Re: VB6: Best way to find all permutations of a given string in a file - Contest
Very impressive. A few minor issues running it, but nothing I couldn't figure out in a few seconds. (Except I seem to be missing clsContestant.cls)
One note is that the benchmark program seems to leave a bunch of zero-byte text files laying around. Not a big deal, obviously, but you may want to check that if you use a similar technique in other projects.
Re: VB6: Best way to find all permutations of a given string in a file - Contest
File updated. Sorry about that. Yeah, those files were actually logs but they were not turned off completely.