Files
wren/example/benchmark/fib.wren
T
retoor 8f1d13a86b feat: add networking module with TCP Socket/Server and example applications
Implement a full-featured `net` module supporting TCP `Socket` and `Server` classes via libuv, including example applications (chat server, echo server, HTTP client/server, file explorer, system dashboard) and benchmark scripts (fibonacci, n-body). Add GEMINI.md project documentation and Stderr class to io module.
2026-01-24 08:57:59 +00:00

16 lines
286 B
JavaScript
Vendored

import "os" for Process
var start = System.clock
var fib
fib = Fn.new { |n|
if (n < 2) return n
return fib.call(n - 1) + fib.call(n - 2)
}
for (i in 1..5) {
System.print("fib(28) = " + fib.call(28).toString)
}
System.print("Elapsed: " + (System.clock - start).toString + "s")