Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

double value

 
fabio chumpitaz
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
find the ceiling of a double value and write a method to find its floor.
the ceiling of a number d is the smallest integer greater of equal d.
the floor of a number d is the largets integer less than or equal to d.
example...ceiling 5.4 is 6
floor 5.4 is 5
would someone help wiht this?
 
David O'Meara
Rancher
Posts: 13459
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This is the same reply as your other requests.
Sorry, we don't do homework.
We would be happy to help with specific requests if you have any.
Dave
 
Marilyn de Queiroz
Sheriff
Posts: 9059
12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
There are methods in the Math class for this.
 
Dirk Schreckmann
Sheriff
Posts: 7023
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
fabio,
Welcome to JavaRanch!
How have you thought to perhaps begin to solve this problem?
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic