insertSorted True x xs@(min : maxs)
  | min >= x  = xs
  | otherwise = insertSorted False x maxs
insertSorted True x xs@(min : maxs)
  | min >= x  = xs
  | otherwise = insertSorted False x maxs
insertSorted True x xs@(min : maxs)
  | min >= x  = xs
  | otherwise = insertSorted False x maxs