Changeset 796 for confluence/randombubble.py
- Timestamp:
- 07/21/10 11:29:09 (19 months ago)
- Files:
-
- 1 modified
-
confluence/randombubble.py (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
confluence/randombubble.py
r795 r796 1 1 #!/usr/bin/python 2 3 # Copyright 2010 Adrianna Pinska, Simon Cross 4 # This program is distributed under the terms of the GNU General Public License v3 2 5 3 6 import warnings … … 6 9 import random 7 10 from copy import deepcopy 11 from optparse import OptionParser 8 12 from networkx import Graph, connected_components, draw 9 13 … … 49 53 BALLS = range(8) 50 54 ASYM, SYM_HORIZ, SYM_BOTH = range(3) 55 SYMMETRIES = { 56 "asym" : ASYM, 57 "horiz" : SYM_HORIZ, 58 "both" : SYM_BOTH, 59 } 51 60 52 61 def __init__(self, fill_rows, colours, density, symmetry): … … 123 132 return '\n\n'.join([str(l) for l in self.levels]) 124 133 125 126 print LevelSet(10)134 if __name__ == '__main__': 135 print LevelSet(10)
