Re: Fun - Each character at most once
Eugene van der Pijll <[email protected]>
| Newsgroups | gmane.comp.lang.perl.fun |
|---|---|
| Message-ID | <[email protected]> |
[email protected] schreef: > Can anyone improve the above so that it checks the whole of <>, not just one > line? Bonus points for an explicit multi-character message rather than undef > on failure. #!perl -0234 <>=~m{(.)[^$/]*\1}sand&two contains no characters twice (except for the final \n), checks the whole of <>, and prints a not-very-appropriate message on failure. Eugene