fun oldest (dates: (intintint) list) = if null dates then NONE else let val ans = oldest(tl dates) in if isSome ans andalso is_older(valOf ans, hd date