mirror of
https://github.com/wren-lang/wren.git
synced 2026-01-11 14:18:42 +01:00
Mainly to get rid of one top level directory. But this will also be useful when there are tests of the embedding API.
11 lines
219 B
Lua
11 lines
219 B
Lua
function fib(n)
|
|
if n < 2 then return n end
|
|
return fib(n - 2) + fib(n - 1)
|
|
end
|
|
|
|
local start = os.clock()
|
|
for i = 1, 5 do
|
|
io.write(fib(28) .. "\n")
|
|
end
|
|
io.write(string.format("elapsed: %.8f\n", os.clock() - start))
|