Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:
print "Please give me a number:\n"; my $initial_number = <STDIN>; chomp $initial_number; print "Give me another number:\n"; my $new_number = <STDIN>; if($new_number>=$initial_number) { print "Please continue with a new number:"; } else { print "You specified a number which is smaller than the previous. +The program will now exit\n"; exit; }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Any tips on this?
by toolic (Bishop) on Feb 04, 2014 at 17:08 UTC | |
by Anonymous Monk on Feb 04, 2014 at 17:58 UTC | |
by Anonymous Monk on Feb 04, 2014 at 20:50 UTC | |
|
Re: Any tips on this?
by Eily (Monsignor) on Feb 04, 2014 at 17:03 UTC | |
|
Re: Any tips on this?
by simmisam (Novice) on Feb 05, 2014 at 07:02 UTC |