It's hard to decipher exactly what you want to do. It's easy to say that should always give $this_user eq 'robot'; because, if $this_user must be 0, 1, or 2, then it will never be less than 0. Try doing it by subscripting a list:
$this_user = qw( male female robot )[$this_user];
Rearrange to taste.
-sauoq "My two cents aren't worth a dime.";
In reply to Re: Conditional variable assignments
by sauoq
in thread [untitled node, ID 260676]
by Samn
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |