Simpler yet!
use strict; use warnings; my $modules = shift; my $second_group = int($modules/2); printf "Call %d on port 80, %d on port 8080\n", $modules - $second_group, $second_group;
Yeah, brain circuits were irrevocably committed to using ceil() in there somewhere, to no real point in a simple case like this.
In reply to Re^3: Ceiling elements of an array!
by GotToBTru
in thread Ceiling elements of an array!
by shadowman13
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |