summaryrefslogtreecommitdiff
path: root/2025/ocaml/lib
diff options
context:
space:
mode:
authorDJ O'Leary <dijitol@proton.me>2025-12-04 01:50:23 +0100
committerDJ O'Leary <dijitol@proton.me>2025-12-04 01:50:23 +0100
commit8ff2c5016d4359c4d5d583c7fc78a66f296bdebc (patch)
treec3379be366e06b1082250c0c78e09979dbe87065 /2025/ocaml/lib
parent71d2a248c13739f3839de1f65f3739d9cfc3c8be (diff)
feat(2025d3p1): create skeleton
Diffstat (limited to '2025/ocaml/lib')
-rw-r--r--2025/ocaml/lib/application/d03p01.ml1
-rw-r--r--2025/ocaml/lib/application/d03p01.mli4
-rw-r--r--2025/ocaml/lib/domain/d03p01.ml0
-rw-r--r--2025/ocaml/lib/presentation/cli.ml4
4 files changed, 9 insertions, 0 deletions
diff --git a/2025/ocaml/lib/application/d03p01.ml b/2025/ocaml/lib/application/d03p01.ml
new file mode 100644
index 0000000..26319df
--- /dev/null
+++ b/2025/ocaml/lib/application/d03p01.ml
@@ -0,0 +1 @@
+let solve _ () = failwith "not started"
diff --git a/2025/ocaml/lib/application/d03p01.mli b/2025/ocaml/lib/application/d03p01.mli
new file mode 100644
index 0000000..85f7e78
--- /dev/null
+++ b/2025/ocaml/lib/application/d03p01.mli
@@ -0,0 +1,4 @@
+val solve : string -> unit -> int
+(** [solve input ()] is the solution for the first part of the third day of advent of code 2025 for [input].
+ The solution for an empty input is 0.
+ Requires: [input] to be a string. *)
diff --git a/2025/ocaml/lib/domain/d03p01.ml b/2025/ocaml/lib/domain/d03p01.ml
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/2025/ocaml/lib/domain/d03p01.ml
diff --git a/2025/ocaml/lib/presentation/cli.ml b/2025/ocaml/lib/presentation/cli.ml
index 6f5a548..5863d21 100644
--- a/2025/ocaml/lib/presentation/cli.ml
+++ b/2025/ocaml/lib/presentation/cli.ml
@@ -16,6 +16,10 @@ let run_day _ = function
run_solver "D02P01" Application.D02p01.solve filepath ;
run_solver "D02P02" Application.D02p02.solve filepath ;
0
+ | 3 ->
+ let filepath = "../_input/day_03.txt" in
+ run_solver "D03P01" Application.D03p01.solve filepath ;
+ 0
| _ ->
failwith "day not implemented"