mirror of
https://github.com/NeoFlock/neonucleus.git
synced 2025-09-24 09:03:32 +02:00
9 lines
263 B
Lua
9 lines
263 B
Lua
local computer = require("computer")
|
|
local total = computer.totalMemory()
|
|
local max = 0
|
|
for _=1,40 do
|
|
max = math.max(max, computer.freeMemory())
|
|
os.sleep(0) -- invokes gc
|
|
end
|
|
io.write(string.format("Total%12d\nUsed%13d\nFree%13d\n", total, total - max, max))
|