r/adventofcode • u/daggerdragon • Dec 03 '18
SOLUTION MEGATHREAD -🎄- 2018 Day 3 Solutions -🎄-
--- Day 3: No Matter How You Slice It ---
Post your solution as a comment or, for longer solutions, consider linking to your repo (e.g. GitHub/gists/Pastebin/blag or whatever).
Note: The Solution Megathreads are for solutions only. If you have questions, please post your own thread and make sure to flair it with Help.
Advent of Code: The Party Game!
ATTENTION: minor change request from the mods!
Please prefix your card submission with something like [Card] to make scanning the megathread easier. THANK YOU!
Card prompt: Day 3 image coming soon - imgur is being a dick, so I've contacted their support.
Transcript:
I'm ready for today's puzzle because I have the Savvy Programmer's Guide to ___.
This thread will be unlocked when there are a significant number of people on the leaderboard with gold stars for today's puzzle.
edit: Leaderboard capped, thread unlocked!
42
Upvotes
View all comments
Show parent comment
1
u/HyjinxRavepaws Dec 10 '18 edited Dec 10 '18
std::istream &operator>>(std::istream &is, Claim &claim)Can you explain how this block works? I've tried several different options to parse the input, and nothing I can come up with works. This worked for me, and allowed me to solve the problem with the rest of the what I had written, but I don't understand how this works and don't really like leaving a question unanswered and saying 'but it's right'
Edit: I was finally able to dig up a solution to the question of 'how does this work' and now I feel stupid. [well, stupid that I didn't find it before, not that I didn't know how it worked]