You are viewing a single comment's thread. Return to all comments →
Probably not the best Erlang code:
-module(solution). -export([main/0, read_input/1]). read_input(X) -> case io:fread("", "~d") of eof -> ok; {ok, [N]} -> if N < X -> io:format("~p~n", [N]); N >= X -> ok end, read_input(X) end. main() -> {ok,[X]} = io:fread("", "~d"), read_input(X).
Seems like cookies are disabled on this browser, please enable them to open this website
Filter Array
You are viewing a single comment's thread. Return to all comments →
Probably not the best Erlang code: