Happy Pi Day!
Today is 3/14… Pi Day! And in honor of this great day, James Tauber wrote a Python script to generate the hex digits of pi. Nice!
If you are so inclined, Wikipedia has a nice article on the various methods of computing pi. Here’s my favorite method:
#!/usr/bin/env python
from math import pi
print pi
Heh.

Liar
>>> import pi
Traceback (most recent call last):
File “”, line 1, in ?
ImportError: No module named pi
Heh, oops, I read this in bloglines which had messed up the formatting
Heh.
You could also do `import math` and then call it as math.pi. :P