Erlang learning and basic programming