From 02c55e2f55be5b012d311a3bfcf4a4515881819e Mon Sep 17 00:00:00 2001 From: DJ O'Leary Date: Thu, 11 Dec 2025 03:54:45 +0100 Subject: feat(2025d5): add skeleton for problem --- 2025/ocaml/lib/application/d05p01.ml | 3 +++ 2025/ocaml/lib/application/d05p01.mli | 4 ++++ 2 files changed, 7 insertions(+) create mode 100644 2025/ocaml/lib/application/d05p01.ml create mode 100644 2025/ocaml/lib/application/d05p01.mli (limited to '2025/ocaml/lib/application') diff --git a/2025/ocaml/lib/application/d05p01.ml b/2025/ocaml/lib/application/d05p01.ml new file mode 100644 index 0000000..4bf79ab --- /dev/null +++ b/2025/ocaml/lib/application/d05p01.ml @@ -0,0 +1,3 @@ +let err_empty_input = "input is empty" + +let solve input () = if input = "" then Error err_empty_input else Ok 0 diff --git a/2025/ocaml/lib/application/d05p01.mli b/2025/ocaml/lib/application/d05p01.mli new file mode 100644 index 0000000..85c3dd5 --- /dev/null +++ b/2025/ocaml/lib/application/d05p01.mli @@ -0,0 +1,4 @@ +val solve : string -> unit -> (int, string) result +(** [solve input ()] is the solution for the first part of the five day of advent of code 2025 for [input]. + The solution for an empty input is [Error msg]. + Requires: [input] to be a string. *) -- cgit v1.2.3