blob: c9a3130313c924355d892f3393779ee9cf54e62a (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
|
{-# OPTIONS_GHC -fno-warn-redundant-constraints #-}
module T5342 (increaseAreas) where
import Control.Monad
import Data.List
nubSorted :: Eq a => [a] -> [a]
nubSorted = undefined
cellsAround :: (Num a, Num b, Ord a, Ord b) => [(a, b)] -> [(a, b)]
cellsAround = undefined
increaseAreas :: (Num a, Num b, Ord a, Ord b) => [[(a, b)]] -> [[(a, b)]]
increaseAreas areas
= nubSorted $ sort $
do
area <- areas
cell2 <- cellsAround area
return $ sort $ cell2 : area
|