in reply to print list, comma not working?
Notice the parens around print, its essentially like( my $i = 0 ); foreach $_ ( 1 .. 456 ) { ( print( ( ( $i % 100 ) ? '' : "\n\t" ) ), ( ( $i % 10 ) ? '???' : int( ( ( $i % 100 ) / 10 ) ) ) ); ( ++$i ); } print("\n");
2nd part$ perl -le"print(1),2" 1
( my $i = 0 ); foreach $_ ( 1 .. 456 ) { print( ( ( $i % 100 ) ? '' : "\n\t" ) ); print( ( ( $i % 10 ) ? '.' : int( ( ( $i % 100 ) / 10 ) ) ) ); ( ++$i ); } print("\n");
|
|---|