RosettaCodeData/Task/Count-in-octal/Ring/count-in-octal.ring
2016-12-05 23:44:36 +01:00

14 lines
240 B
Text

size = 30
for n = 1 to size
see octal(n) + nl
next
func octal m
output = ""
w = m
while fabs(w) > 0
oct = w & 7
w = floor(w / 8)
output = string(oct) + output
end
return output