Juho Snellman <[EMAIL PROTECTED]> writes: > On Wed, Sep 01, 2004 at 08:34:32PM +0100, McGlinchy, Alistair wrote: >> Puzzle: Write a one-liner longer than (say) 3 bytes that can improve >> on 0.77 distinct warnings per byte of code. The program should be -c >> valid, output nothing without -w and sound the alarm as much as >> possible with -w. > > 4 bytes, 5 warnings for 1.25 warnings / byte. > 13 bytes, 13 warnings for 1.00 warnings / byte. 3 bytes, 5 warnings for 1.66 warnings / byte
If we go down to a one byte program then you can get 2 warnings/byte. But you knew that. > S > > P > > O > > I > > L > > E > > R > > > > S > > P > > A > > C > > E $ perl -we 'a<a' Unquoted string "a" may clash with future reserved word at -e line 1. Unquoted string "a" may clash with future reserved word at -e line 1. Useless use of numeric lt (<) in void context at -e line 1. Argument "a" isn't numeric in numeric lt (<) at -e line 1. Argument "a" isn't numeric in numeric lt (<) at -e line 1. $ perl -we 'a' Unquoted string "a" may clash with future reserved word at -e line 1. Useless use of a constant in void context at -e line 1.
