Reverse words solution in Erlang - my first erlang program ever