// Factorial function demonstrating recursion // // Expected output: 10! = 3628800 fn factorial(n: Int): Int = if n <= 1 then 1 else n * factorial(n - 1) // Calculate factorial of 10 let result = factorial(10) // Print result using Console effect fn showResult(): Unit with {Console} = Console.print("10! = " + toString(result)) let output = run showResult() with {}