/mobile Handheld Friendly website
Ubuntu : Intel® Q6600® one core |
Each table row shows performance measurements for this Python 3 program with a particular command-line input value N.
| N | CPU secs | Elapsed secs | Memory KB | Code B | ≈ CPU Load |
|---|---|---|---|---|---|
| 1,000 | Failed | 304 |
Read the ↓ make, command line, and program output logs to see how this program was run.
Read mandelbrot benchmark to see what this program should do.
Python 3.3.1 (default, Apr 11 2013, 12:56:47) [GCC 4.7.2] on linux
# The Computer Language Benchmarks Game # http://benchmarksgame.alioth.debian.org/ # # contributed by Tupteq # 2to3 - fixed by Daniele Varrazzo import sys def main(): cout = sys.stdout.buffer.write size = int(sys.argv[1]) xr_size = range(size) xr_iter = range(50) bit = 128 byte_acc = 0 cout(("P4\n%d %d\n" % (size, size)).encode('ascii')) size = float(size) for y in xr_size: fy = 2j * y / size - 1j for x in xr_size: z = 0j c = 2. * x / size - 1.5 + fy for i in xr_iter: z = z * z + c if abs(z) >= 2.0: break else: byte_acc += bit if bit > 1: bit >>= 1 else: cout((byte_acc,)) bit = 128 byte_acc = 0 if bit != 128: cout((byte_acc,)) bit = 128 byte_acc = 0 main()
Fri, 12 Apr 2013 11:11:19 GMT
MAKE:
mv mandelbrot.python3-3.python3 mandelbrot.python3-3.py
0.01s to complete and log all make actions
COMMAND LINE:
/usr/local/src/Python-3.3.1/bin/python3.3 mandelbrot.python3-3.py 1000
PROGRAM FAILED
(BINARY) PROGRAM OUTPUT NOT SHOWN
Traceback (most recent call last):
File "mandelbrot.python3-3.py", line 45, in <module>
main()
File "mandelbrot.python3-3.py", line 36, in main
cout((byte_acc,))
TypeError: 'tuple' does not support the buffer interface