Win a copy of Kotlin in Action this week in the Kotlin forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

please help me today after tomorrow  RSS feed

 
patrick kobi
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Design and implement a class called Box that contains instance data that represents the height, width and depth of the box. Also include a boolean variable called full as instance data that represents if the box is full or not. Define the Box constructor to accept and initialize the height, width and depth of the box. Each newly created Box is empty (the constructor should initialize full to false). Include getter and setter methods for all instance data. Include a toString method that returns a one-line description of the box. Create a driver class called BoxTest, whose main method instantiates and updates several Box objects.
Thanks a lot,
Patrick
 
Ulf Dittmer
Rancher
Posts: 42972
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
That sounds like a homework assignment that you should be working on in order to learn something. So: What thoughts have you had so far? Where are you stuck implementing them?
 
patrick kobi
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello Sherrif... thanks to reply to my message.... i have a big problem with this exercise because i was sick for a week.... so i want from you just to send the solution... and i will say thank you anyways
 
abhishek pendkay
Ranch Hand
Posts: 184
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
is it really going to help you if one of the ranchers writes the code for you... instead why dont you try it yourself and we can then tell you if its right or wrong...also looking at your assignment it does not look very difficult
 
Ulf Dittmer
Rancher
Posts: 42972
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If you were sick I'm sure you can get an extension from your teacher. As was said elsewhere, ShowSomeEffort and DoYourOwnHomework. JavaRanch is NotACodeMill. We also have other hints on HowToAskQuestionsOnJavaRanch.
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!