xref: /freebsd/contrib/one-true-awk/testdir/p.44 (revision 7ef62cebc2f965b0f640263e179276928885e33d)
1function fact(n) {
2	if (n <= 1)
3		return 1
4	else
5		return n * fact(n-1)
6}
7{ print $1 "! is " fact($1) }
8