Data update
This commit is contained in:
parent
5150844a7d
commit
4bb20c9b71
7735 changed files with 38060 additions and 199180 deletions
|
|
@ -4,7 +4,7 @@ import Text.Printf (printf)
|
|||
-- spiral is the first row plus a smaller spiral rotated 90 deg
|
||||
spiral 0 _ _ = [[]]
|
||||
spiral h w s = [s .. s+w-1] : rot90 (spiral w (h-1) (s+w))
|
||||
where rot90 = (map reverse).transpose
|
||||
where rot90 = (map reverse).transpose
|
||||
|
||||
-- this is sort of hideous, someone may want to fix it
|
||||
main = mapM_ (\row->mapM_ ((printf "%4d").toInteger) row >> putStrLn "") (spiral 10 9 1)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue