Skip to content

Instantly share code, notes, and snippets.

@daenomo
Created June 22, 2012 17:25
Show Gist options
  • Select an option

  • Save daenomo/2974087 to your computer and use it in GitHub Desktop.

Select an option

Save daenomo/2974087 to your computer and use it in GitHub Desktop.
erlang で reverse
-module(reverse).
-export([reverse/1]).
reverse(List) ->
case List of
[] -> [];
[Head|Tail] -> reverse(Tail) ++ [Head]
end.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment