-- Luaa={}for i = 2, math.sqrt(100), 1 do for j = i + i, 99, i do a[j] = 1 endendfor i = 2, 99, 1 do if not a[i] then print(i) endend
マイナー過ぎるか
-- Lua
a={}
for i = 2, math.sqrt(100), 1 do
for j = i + i, 99, i do
a[j] = 1
end
end
for i = 2, 99, 1 do
if not a[i] then
print(i)
end
end