aoc2017-0.1.0.0: Advent of Code 2017 - my answers

Safe HaskellSafe
LanguageHaskell2010

Day6

Description

 

Synopsis

Documentation

parse :: (IArray a e, Ix i, Num i, Read e) => String -> a i e Source #

Reads the words of a string to an array.

top :: (IArray a e, Ix i, Ord e) => a i e -> (i, e) Source #

Returns the index and value of first maximum in an array.

redistribute :: (IArray a i, Integral i, Ix i) => a i i -> a i i Source #

Removes the first maximum and redistributes its value throughout the array.

indexDup :: Ord a => [a] -> Maybe (Int, Int) Source #

The indices of the first two duplicated elements in a list.