Mandelbrot benchmark: make N into a parameter
Make the size of the benchmark be configurable at the command-line, as we do
with the other benchmarks
local Complex = require(arg[1])
+local N = tonumber(arg[2]) or 256
local function level(x, y)
local c = Complex.new(x, y)
@@ -15,13 +16,11 @@ local xmin = -2.0
local xmax = 2.0
local ymin = -2.0
local ymax = 2.0
-local N = 256
local dx = (xmax - xmin) / N
local dy = (ymax - ymin) / N
print("P2")
---print("# mandelbrot set", xmin, xmax, ymin, ymax, N)
print(N, N, 255)
for i = 1, N do
