A date parser made in Erlang