It was kind of more like coming up with organized snippets and notes while understanding a problem.
I'm expressing the wish that were I better at organizing them better that I could have tangled all of those snippets into a working (if ugly) source file and work from there.
Ohh I see, yeah. I usually draw diagrams or write pseudo-code out on paper (or both combined) when trying to grasp something difficult but "notebook-style" exploration also sounds interesting.