in reply to RE (tilly) 2: Find anagrams
in thread Find anagrams

Well, it appears there are two problems. One is that it's O/S intolerant, and doesn't handle files with CR/LF. The other is that if a word occurs twice (like 'for') it prints 'for for'.

The first problem was caused by using NOTEPAD.EXE to save some text I cut and pasted from a website to test it.

Nonetheless, example programs *should* have some sample input and output. After all, if it was a "bug in your version of Perl", how would I know what to expect if it worked?

--Chris

e-mail jcwren

Replies are listed 'Best First'.
RE (tilly) 3: Find anagrams
by tilly (Archbishop) on Sep 21, 2000 at 02:50 UTC
    Neither problem is a problem. On Windows your version of Perl should read by default as a text file and it will be fine. In Unix binary and text works fine. The only issue is if you read a DOS file in Unix, in which case I would trust no script not specifically designed to do that. (My production ones are though.) As for "for" and "for" working, the spec said find anagrams. Not find unique anagrams. The program works according to what my co-worker specified.

    As for the input, output issue, mea culpa.