Skip to content

Instantly share code, notes, and snippets.

@ricjhill
ricjhill / day18.py
Created March 24, 2022 11:57 — forked from joshbduncan/day18.py
Advent of Code 2021 - Day 18
import itertools
import math
import re
def add(data):
if " + " in data:
data = f"[{data.split(' + ')[0]},{data.split(' + ')[1]}]"
return data