Talk:Monitor (ComputerCraft)/@comment-74.74.102.120-20120822130220/@comment-50.77.103.53-20120823030947

If you mean round it to the nearest whole integer:

'''function round(num, idp) local mult = 10^(idp or 0) return math.floor(num * mult + 0.5) / mult end'''

'''x = 1.4 print(round(x, 0))'''

That would output 1, or if x = 1.6 it would output 2.