Try to ... chomp $ask; if ($ask eq "1") .... Or enter Add instead of 1 (you still need to chomp($ask)).
Some more hints:
In reply to Re: my program will not display a correct answer, to a random question?
by Anonymous Monk
in thread my program will not display a correct answer, to a random question?
by rse2
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |