Skip to content

Instantly share code, notes, and snippets.

@lukewestby
Created June 15, 2016 14:57
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save lukewestby/920aa1e7a0bae3e63758466ada5a210b to your computer and use it in GitHub Desktop.
Save lukewestby/920aa1e7a0bae3e63758466ada5a210b to your computer and use it in GitHub Desktop.
JortSort Elm Port
module JortSort exposing (jortSort)
jortSort : List comparable -> Bool
jortSort list =
let
-- sort the list
sortedList =
List.sort list
in
-- compare to see if it was originally sorted
list == sortedList
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment