http://qs321.pair.com?node_id=861878


in reply to Can't understand function returning undefs

if( ()=(0,0) ) { print "sometimes you're counting the things in the list and getting +2.\n" } if( (0,0) ) { print "sometimes you're applying the comma operator and getting und +ef (last)\n"; }

if is going to boolean test, so it's rather like this:

use Data::Dumper; print Dumper({ test1=>scalar( 7,13 ), test2=>scalar( ()=(7,13) ) }), " +\n";