http://www.perlmonks.org?node_id=975609


in reply to if statement confusion

Write it like this:

$ans = 6 < 8 ? 'true' : 'false';

update: Aack! I didn't notice that toolic had already given this suggestion. Sorry for creating an echo in the Monastery. :)


Dave