# d5b3d6397c395348e210d1b7ae7db838e32c083d737001631bbe22cacd537867 Elan 1.8.0 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
