1.1 --- a/ula.py Sun Dec 11 01:02:06 2011 +0100
1.2 +++ b/ula.py Sun Dec 11 01:11:35 2011 +0100
1.3 @@ -4,9 +4,6 @@
1.4 Acorn Electron ULA simulation.
1.5 """
1.6
1.7 -import array
1.8 -import itertools
1.9 -
1.10 WIDTH = 640
1.11 HEIGHT = 512
1.12 INTENSITY = 255
1.13 @@ -284,7 +281,7 @@
1.14
1.15 "Return an array representing the computer's memory."
1.16
1.17 - return array.array("B", itertools.repeat(0, MAX_MEMORY))
1.18 + return [0] * MAX_MEMORY
1.19
1.20 def get_screen():
1.21
1.22 @@ -293,12 +290,7 @@
1.23 x = 0
1.24 screen = []
1.25 while x < WIDTH:
1.26 - y = 0
1.27 - column = []
1.28 - while y < HEIGHT:
1.29 - column.append((0, 0, 0))
1.30 - y += 1
1.31 - screen.append(column)
1.32 + screen.append([(0, 0, 0)] * HEIGHT)
1.33 x += 1
1.34 return screen
1.35