Looking for my $200…

Twelve Blocks?

Nefarious and I went on her first long-distance bike ride and biked to the park and back. Yes, I have tassels too but it’s because I am riding Caitlin’s bike… After that adventure we sowed a planter full of her pick, moonflowers (a climbing vine with huge white flowers), and a second one full of sunfowers, my pick. There’s another planter with chives and other herbs that survived the winter already growing nicely…

Extreme Apnea

My ability to hold my breath maxes out at around five minutes if I relax and focus (which I think is pretty impressive), and about half that on a normal high-on-taurine-and-caffeine sort of day. David Blaine just held his breath for 17 minutes and 4 seconds… Wow…!

Fail Peanuts!

The following submissions did not quite meet Caitlin and my strict criteria for things that look like ducks. Click that link to see what has made the cut lately (I added a few new ones today), and please email me your things that look like ducks at duckpeanut@gmail.com!

Colour Sequencing / Combinatorics Tool

Caitlin needed a tool for creating lists of every possible combination of a set of variables (including the ability to limit the list length) so I wrote her a quick command line tool for doing that. She’s using it to output lists of every combination of yarn to make sure that every panel in a quilt-like thing (watch for it here in the future perhaps). Here’s how it works:

SEQUENCES
Note: you can also enter your variables on the command line, comma separated
Enter your variables now:
-->red,green,blue,black
Depth limitation? (Blank for no)
-->3
red, green, blue
red, green, black
red, blue, green
red, blue, black
red, black, green
red, black, blue
green, red, blue
green, red, black
green, blue, red
green, blue, black
green, black, red
green, black, blue
blue, red, green
blue, red, black
blue, green, red
blue, green, black
blue, black, red
blue, black, green
black, red, green
black, red, blue
black, green, red
black, green, blue
black, blue, red
black, blue, green

<press any key to exit>

So it outputs every possible combination, with order being important, with no repetition of colour inside the set, with the length of list limited as you desire (if at all). You can run it either by clicking it or running it from a prompt, or you can enter the list as the command line variables and redirect it to a file since it writes to stdio.

Source code* (PBCC) is included; download it here:
https://zentastic.me/code/sequences.zip [12k]

* It’s actually a useful piece of code for people looking to learn about how to write recursive software… this type of combinatorial processing is a great use for recursion. I should mention that the length limitation is a kind of sloppy add-on that uses global variables which is kind of frowned upon.