Mode:
Duration:
1
2
3
4
5
6
7
8
9
add = fn a, b -> a + b end
subtract = fn a, b -> a - b end
multiply = fn a, b -> a * b end
divide = fn a, b -> a / b end
IO.puts("Add 5 + 3: #{add.(5,3)}")
IO.puts("Subtract 5 - 3: #{subtract.(5,3)}")
IO.puts("Multiply 5 * 3: #{multiply.(5,3)}")
IO.puts("Divide 6 / 2: #{divide.(6,2)}")Coding works best on desktop or with an external keyboard.