Hi! I'm reading the tutorial and I think in "defining functions" this:
birds = 3
iguanas = 2
total = Num.toStr (birds + iguanas)
main =
Stdout.line "There are \(total) animals."
addAndStringify = \num1, num2 ->
Num.toStr (num1 + num2)
is meant to be
birds = 3
iguanas = 2
total = addAndStringify birds iguanas
main =
Stdout.line "There are \(total) animals."
addAndStringify = \num1, num2 ->
Num.toStr (num1 + num2)
right?
yeah, should probably be using the addAndStringify
function
Okay, I try to fix that and open a pull request :)
That would be great!
Okay, I hope I did it right :sweat_smile:
Last updated: Jul 06 2025 at 12:14 UTC