in reply to To call a sub from another sub

use strict; use warnings; whatever(); sub whatever { my $value = 5; $value = increment($value); print $value; } sub increment { return $_[0] + 1; }