|
-
Mar 5th, 2008, 11:03 AM
#7
Re: [2005] Word Counter - Any improvments?
I think this solution is overly complicated. To count words, why not use a regular expression? They're very very fast and efficient.
This example is in VB6 but you can still use the same regular expression and the new .Net regex classes to simply count all of the matches. This way you can get your 20-30 lines of code down to about 2-3.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|