added day03

This commit is contained in:
Andrew Maier 2021-12-09 15:54:44 +01:00
parent 4411868464
commit 2eca62528a
5 changed files with 1063 additions and 0 deletions

5
day03/CHANGELOG.md Normal file
View File

@ -0,0 +1,5 @@
# Revision history for day03
## 0.1.0.0 -- YYYY-mm-dd
* First version. Released on an unsuspecting world.

9
day03/app/Main.hs Normal file
View File

@ -0,0 +1,9 @@
module Main where
import Day03 (day03Part1, day03Part2)
main :: IO ()
main = do
input <- readFile "./data/input.txt"
putStrLn $ "Part 1: " <> day03Part1 input
putStrLn $ "Part 2: " <> day03Part2 input

1000
day03/data/input.txt Normal file

File diff suppressed because it is too large Load Diff

42
day03/day03.cabal Normal file
View File

@ -0,0 +1,42 @@
cabal-version: 2.4
name: day03
version: 0.1.0.0
-- A short (one-line) description of the package.
-- synopsis:
-- A longer description of the package.
-- description:
-- A URL where users can report bugs.
-- bug-reports:
-- The license under which the package is released.
-- license:
author: Andrew Maier
maintainer: andrew@maier.name
-- A copyright notice.
-- copyright:
-- category:
extra-source-files: CHANGELOG.md
executable day03
main-is: Main.hs
-- Modules included in this executable, other than Main.
-- other-modules:
-- LANGUAGE extensions used by modules in this package.
-- other-extensions:
build-depends: base ^>=4.14.3.0
, day03
hs-source-dirs: app
default-language: Haskell2010
library
build-depends: base ^>=4.14.3.0
hs-source-dirs: lib
exposed-modules: Day03
default-language: Haskell2010

7
day03/lib/Day03.hs Normal file
View File

@ -0,0 +1,7 @@
module Day03 where
day03Part1 :: String -> String
day03Part1 _ ="Day03 Part1"
day03Part2 :: String -> String
day03Part2 _ ="Day03 Part2"