A buddy of mine asked me a couple days ago if it’d be possible to write a
program that rolled dice and dealt with the results in a certain way. Seeing
this as an opportunity to dabble in some programming I naturally replied
that 1) Yes, it’s possible, and 2) I’ll do it for you.
The obvious choice for the job was
Python.
Anyway, the task took an embarassingly long time (over 3 hours), but I
didn’t feel bad about it considering my limited programming experience.
Plus, the old saying about only getting good at programming by doing it is
quite true.
At any rate, here’s what I came up with for the basic task, which was to
roll 2-9 d6 and add the two highest rolls. From here I’m going to add the
ability to provide a second argument that determines how many times the roll
with x number of dice will be made. That version will also keep a running
average of the totals from each roll.
Having studied Spanish for over 6 years, I knew what dulce de leche meant. Sweet.…
I found kiwis on sale. Five for $1! In the middle of winter. In January.…
An experience. That’s what Ghirardelli is to me. For many years, San Francisco was a…
The challenge: Bring something with a foraged ingredient. My answer: Eucalyptus. Eucalyptus ice cream! Large…
Celery ice cream? It got me thinking. Celery? Green. Usually eaten raw. Almost tasteless, but…
“A cookie must melt at the same rate as the ice cream,” an ice cream…
Leave a Comment