driver.love/0038-order_of_magnitude

3 lines
81 B
Plaintext

order_of_magnitude = function(n)
return math.floor(math.log(n)/math.log(10))
end