diff --git a/erlang/countup.erl b/erlang/countup.erl new file mode 100644 index 0000000..8ce54d3 --- /dev/null +++ b/erlang/countup.erl @@ -0,0 +1,7 @@ +-module(countup). +-export([to/1]). + +to(N) -> to(N, []). + +to(0, Prev) -> Prev; +to(N, Prev) -> to(N - 1, [N | Prev]). \ No newline at end of file