From: Ronnie Aa Date: 2011-12-15T06:53:02+09:00 Subject: round float to integer if whole number Hi, I'm looking for a way to pick out the whole numbers (ff) in the function below: x = 17 w = 4.000 while x > 0 ff = x / w if ff > 0 and ff.is_a? wholenumber puts " #{ff} is a whole number" end x -= 1 end Thanx Liquid -- Posted via http://www.ruby-forum.com/.