This commit is contained in:
Ingy döt Net 2013-06-05 21:47:54 +00:00
parent 1f1ad49427
commit 6f050a029e
2496 changed files with 37609 additions and 3031 deletions

View file

@ -1,10 +1,8 @@
-module(main).
-export([main/1]).
-module(ack).
-export([main/1, ack/2]).
main( [ A | [ B |[]]]) ->
io:fwrite("~p~n",[ack(toi(A),toi(B))]).
toi(E) -> element(1,string:to_integer(E)).
main( [A, B] ) ->
io:fwrite( "~p~n",[ack(erlang:list_to_integer(A), erlang:list_to_integer(B))] ).
ack(0,N) -> N + 1;
ack(M,0) -> ack(M-1, 1);