- or download this
type Data = (Int, Int, String)
...
, (25, 28, "D")
, (47, 49, "E")
]
- or download this
sub bottom { shift->[0] };
sub top { shift->[1] };
...
, [25, 28, "D"]
, [47, 49, "E"]
];
- or download this
rangeSort1 :: [Data] -> [(Data, [Data])]
rangeSort1 r = mapMaybe (\x -> let l = filter (contains x) . filter (/
+=x)
...
otherwise -> Just (x, l r)
) r