Skip to content

Instantly share code, notes, and snippets.

@danielcristofani
Created December 7, 2025 07:34
Show Gist options
  • Select an option

  • Save danielcristofani/ff4539a9adca991ae57da6256be5a09c to your computer and use it in GitHub Desktop.

Select an option

Save danielcristofani/ff4539a9adca991ae57da6256be5a09c to your computer and use it in GitHub Desktop.
brainfuck solution for Advent of Code 2025, day 6, part 2
[2025day6b.b -- 2025 Advent of Code Day 6 Part 2
(c) 2025 Daniel B. Cristofani
http://brainfuck.org/
This program is licensed under a Creative Commons Attribution-ShareAlike 4.0
International License (http://creativecommons.org/licenses/by-sa/4.0/).
This program solves Advent of Code 2025, Day 6, Part 2.
(https://adventofcode.com/2025/day/6)
Assumes EOF="no change" or EOF=0. No assumptions about cell size.]
+++++++[>++++<-]>[-[>>+<<-]>>]+>>>>>>>>>>>>
,[----------[>>>>>>>>>>]<<<<<[>>>>>+<<<<<[<<<<<]>>>>],]
+++++++[++[>]<<<<<<[---<]>]>[
-------------[<<<<<<<+>>>>>>+>+]<->+[
-<+<<++++[
>>[>]>-[
<+++[>-----<-]
>[<<[<]>[<<<<]<+[>>>>]>[>]>-]
<<[<]>[<<<<]+<[>>>>]>[>]>
]<+[<]<-
]<<[-<<<<]>>>[>>>>]>[>]+[-<]>[<]<<<<[>>>]<[>]<[
[<[<<<<]+>]<[>>>>]<<<[<<<<]+[-[<+>-]>>>>]<<<<++>
]<<[>[<<<<]>>>>[[<<<<+>>>>-]>>>>]<<<<<<<<<]
>[<+<<<]>>>>[>>>>]<[
-[>>+<<-]+>>[<<<<<[<<<<]>>>>[[>+>>+<<<-]>[<+>-]>>->]>-]<<<<<[
[>>>>+<<<<-]>++++++++++>>-[>>+<<-]>>
[<<+<<-[<<<<]>>>[<[<<+>>-]<<<<+<<<[->>+<]>[-<]<+>>>>]>>>>>-]
<<+<<[-]<<<<<
]>>>>+[-[+<<<]>>>>]<[>>>>]<
]<<<[<<<<]+[[-]>>>>]>[>>>>>+<<<<<-]>[-]
<<<<<<<[<<<<]+[-[+<<]>>>>]<<[>>>>]<<<<
[[[>>>>>+<<<<<-]<<<<]>>>>>>>>>[>>>>]<<<<<<<<<<]>>>>>>>[>>]>>>>>
]>>
]<<<<<+<<<[++<++++++++<<<]>>>[+[>+++++<-]>.>>>]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment