# 43e2bfa781fbd28e43e80c9a84f0c160411446f9bd802b1b2562e8f1bfd816fd Elan 1.6.4 guest default_profile valid

main
  print factorial(7)
end main

function factorial(n as Int) returns Int
  return (if n > 1 then n*factorial(n - 1) else 1)
end function

test 
  assert factorial(3) is 6
end test
