This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- | |
-- Copyright (C) 2013 Chris McClelland | |
-- | |
-- This program is free software: you can redistribute it and/or modify | |
-- it under the terms of the GNU Lesser General Public License as published by | |
-- the Free Software Foundation, either version 3 of the License, or | |
-- (at your option) any later version. | |
-- | |
-- This program is distributed in the hope that it will be useful, | |
-- but WITHOUT ANY WARRANTY; without even the implied warranty of |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import urllib2, re, time | |
from Tkinter import * | |
import datetime | |
import webbrowser | |
class App: | |
def __init__(self, master): | |
self.master = master | |
frame = Frame(master, bg="") | |
frame.pack() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
''' listing 6: pi_mp.py | |
Multiprocessing based code to estimate the value of PI | |
using monte carlo sampling | |
Ref: http://math.fullerton.edu/mathews/n2003/montecarlopimod.html | |
Uses workers: | |
http://docs.python.org/library/multiprocessing.html#module-multiprocessing.pool | |
''' | |
import random |