mirror of
https://github.com/rjNemo/ai_advent_code_2024
synced 2026-06-06 10:36:46 +00:00
This commit: - Moves input files to priv/inputs/day1/ - Creates solutions directory in lib/advent_code2024/solutions/ - Adds README.md with problem description - Updates module and import paths - Removes old directory structure
29 lines
762 B
Elixir
29 lines
762 B
Elixir
defmodule AdventCode2024.Solution do
|
|
@moduledoc """
|
|
Behaviour module defining the interface for Advent of Code daily solutions.
|
|
"""
|
|
|
|
@doc """
|
|
Solves Part 1 of a daily challenge.
|
|
|
|
## Parameters
|
|
- input_file: Path to input file
|
|
|
|
## Returns
|
|
- `{:ok, result}` where result is the solution
|
|
- `{:error, reason}` if processing fails
|
|
"""
|
|
@callback solve(input_file :: String.t()) :: {:ok, any()} | {:error, String.t()}
|
|
|
|
@doc """
|
|
Solves Part 2 of a daily challenge.
|
|
|
|
## Parameters
|
|
- input_file: Path to input file
|
|
|
|
## Returns
|
|
- `{:ok, result}` where result is the solution
|
|
- `{:error, reason}` if processing fails
|
|
"""
|
|
@callback solve_part2(input_file :: String.t()) :: {:ok, any()} | {:error, String.t()}
|
|
end
|