
use strict 'vars';
die "Usage: $0 number\n" unless @ARGV == 1;

my $n = factorial($ARGV[0]);
print "$ARGV[0] factorial is $n.\n";

sub factorial {
  my ($n) = @_;
  if ($n == 0) { return 1 }
  else { return $n * factorial($n-1) }
}




