>> head (a : rest) == a >> ins x [] == [x] >> ins x (a : rest) == x : a : rest \ > <| x < a |> \ > a : ins x rest >> sort [] == [] >> sort (a : rest) == ins a (sort rest) >> sort [8, 0, 4, 1, 7, 9, 5, 2, 6] sort 8 : 0 : 4 : 1 : 7 : 9 : 5 : 2 : 6 : [] ins 8 (sort 0 : 4 : 1 : 7 : 9 : 5 : 2 : 6 : []) ins 8 (ins 0 (sort 4 : 1 : 7 : 9 : 5 : 2 : 6 : [])) ins 8 (ins 0 (ins 4 (sort 1 : 7 : 9 : 5 : 2 : 6 : []))) ins 8 (ins 0 (ins 4 (ins 1 (sort 7 : 9 : 5 : 2 : 6 : [])))) ins 8 (ins 0 (ins 4 (ins 1 (ins 7 (sort 9 : 5 : 2 : 6 : []))))) ins 8 (ins 0 (ins 4 (ins 1 (ins 7 (ins 9 (sort 5 : 2 : 6 : [])))))) ins 8 (ins 0 (ins 4 (ins 1 (ins 7 (ins 9 (ins 5 (sort 2 : 6 : []))))))) ins 8 (ins 0 (ins 4 (ins 1 (ins 7 (ins 9 (ins 5 (ins 2 (sort 6 : [])))))))) ins 8 (ins 0 (ins 4 (ins 1 (ins 7 (ins 9 (ins 5 (ins 2 (ins 6 (sort []))))))))) ins 8 (ins 0 (ins 4 (ins 1 (ins 7 (ins 9 (ins 5 (ins 2 (ins 6 [])))))))) ins 8 (ins 0 (ins 4 (ins 1 (ins 7 (ins 9 (ins 5 (ins 2 (6 : [])))))))) ins 8 (ins 0 (ins 4 (ins 1 (ins 7 (ins 9 (ins 5 (2 : 6 : []))))))) ins 8 (ins 0 (ins 4 (ins 1 (ins 7 (ins 9 (2 : (ins 5 (6 : [])))))))) ins 8 (ins 0 (ins 4 (ins 1 (ins 7 (2 : (ins 9 (ins 5 (6 : [])))))))) ins 8 (ins 0 (ins 4 (ins 1 (2 : (ins 7 (ins 9 (ins 5 (6 : [])))))))) ins 8 (ins 0 (ins 4 (1 : (2 : (ins 7 (ins 9 (ins 5 (6 : [])))))))) ins 8 (ins 0 (1 : (ins 4 (2 : (ins 7 (ins 9 (ins 5 (6 : [])))))))) ins 8 (0 : 1 : (ins 4 (2 : (ins 7 (ins 9 (ins 5 (6 : [])))))))) 0 : (ins 8 (1 : (ins 4 (2 : (ins 7 (ins 9 (ins 5 (6 : []))))))))) min print continue