in reply to Testing for 16 possible combinations with 4 pull-down menus

Screams lookup table to me ...

sub validate { return ($_[0] < $_[1]) } %lookup = { '0000' => &validate($start,$end), '0001' => false, '0010' => false, . . . '1111' => &validate($start,$end) }; . . . if ($lookup{$switch_binary}) { # Result is valid } else { # Call user a pudding-head }

The intelligent reader will judge for himself. Without examining the facts fully and fairly, there is no way of knowing whether vox populi is really vox dei, or merely vox asinorum. -- Cyrus H. Gordon