This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Increase $File::Glob::VERSION to 1.18
[perl5.git] / lib / perl5db / t / fact
1 #!/usr/bin/perl
2
3 use strict;
4 use warnings;
5
6 sub fact {
7     my $n = shift;
8     if ($n > 1) {
9         return $n * fact($n - 1);
10     } else {
11         return 1;
12     }
13 }
14 fact(5);