• Post Reply Bookmark Topic Watch Topic
  • New Topic

Math.floor() and Math.ceil()  RSS feed

 
Josh Mickley
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am beginning this thread because I am curious to find out why:

and


return doubles as opposed to ints. What was the rationale behind this decision? All input is welcomed...
 
Josh Mickley
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Actually, after giving this further thought, I believe the reason double is returned is to support larger numbers. (Since the int primitive type is limited to 32 bits)
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!