Skip to content

Instantly share code, notes, and snippets.

@kunishi
Created January 29, 2014 10:18
Show Gist options
  • Save kunishi/8685124 to your computer and use it in GitHub Desktop.
Save kunishi/8685124 to your computer and use it in GitHub Desktop.
fun maxList(L) =
if tl(L) = nil
then hd(L)
else
let
val x = hd(L);
val y = maxList(tl(L))
in
if x<y then y else x
end;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment