X-Git-Url: https://git.njae.me.uk/?a=blobdiff_plain;f=advent07%2FMainWithCase.hs;h=bd0aa85906dab170f5235500673f0ca25d3786f7;hb=14a708ee545a9bd6d81205177ab9baabd29d1894;hp=e5a181fd6217a43804e9233f71cdd6eb1c99d7fe;hpb=c4136e04dca618af23f2bbc30dc1045afb8a6bac;p=advent-of-code-23.git diff --git a/advent07/MainWithCase.hs b/advent07/MainWithCase.hs index e5a181f..bd0aa85 100644 --- a/advent07/MainWithCase.hs +++ b/advent07/MainWithCase.hs @@ -71,7 +71,7 @@ handP :: Parser Hand cardP :: Parser Card handsP = handP `sepBy` endOfLine -handP = Hand <$> ((many1 cardP) <* space) <*> decimal +handP = Hand <$> many1 cardP <* space <*> decimal cardP = (Two <$ "2") <|> (Three <$ "3") <|> (Four <$ "4") <|> (Five <$ "5") <|> (Six <$ "6") <|> (Seven <$ "7") <|>