[PyAR2] Flipping coins

Daniel Veazey daniel at danielveazey.com
Wed Mar 7 16:53:29 CET 2012

Hi everyone, it's been a little while since I saw any activity on this
list, so I decided to share what I was working on last night. It's very
beginner stuff, but it was fun to write.

I've been watching videos on khanacademy.org, and I wrote a program that
tests the concept shown in this video:

Here is my code:

I wrote the program using floating point variables instead of decimals
because I was having a little trouble working with decimal.Decimal. It
seemed that none of the operations I wanted to do on those variables were
allowed, so I stuck with floating points. I haven't noticed any
discrepancies in the math when I compare the program's results to my

So anyway, there it is. Comments and criticism are welcome.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/mailman/private/pyar2/attachments/20120307/5f631daf/attachment.html>

More information about the PyAR2 mailing list