Where does a Person come from?

  • 3
  • Locked
In Java, people come from the same place that other classes come from: from the programmer's head. It is important for the creator of a class to think through what is important for the class and what is not. If he or she does, then the class will make sense and be useful. Let's begin. Let's create a Person class that allows our Person to have a name, age, weight, and... money. And then we'll create an object.
You can't complete this task, because you're not signed in.
Comments (52)
  • Popular
  • New
  • Old
You must be signed in to leave a comment
9 August, 05:22
Oh wow coding is really unforgiving, everything was fine except i forgot a cap letter on person lol, still really interesting though, can't wait to learn more.
Anonymous #10755035
Level 3 , Paris, France
16 June, 23:06
Hint here: the word "immediately" means you must assign the object Person to the new variable person all in ONE line!!!
Level 3 , Serbia
28 December 2020, 14:06
Sooo, when I tried to verify, it kept telling me that the problem is in the main method(the part where I was to create the Person object), however it turned out that the problem was in the Person class... Anyone happen to know why it was so?
Level 41
31 December 2020, 06:17
Please post your question with the attached solution in the section Help.
Renz dela Paz
Level 2 , Malolos, Philippines
31 October 2020, 03:45
for those who are in creating a new object, I suggest you re-read that Cat example from this lesson. only the first line fulfilled the main method condition. hope this helps as a hint.
anupam jha
Level 7 , India
16 October 2020, 12:59
in the person class created 3 int variables . one string var..in the main method created person object. Person p = new Person(); whats wrong ?? not sure i m.pls clear my confusion.Thanks.
Level 41
19 October 2020, 04:18
Please post your question with the attached solution in the section Help.
Level 7 , Mountain View, United States
24 June 2020, 02:07
how to call a class in another class? help me please.
Level 2 , Beaumont, United States
19 September 2020, 16:23
VariableType variableName = new TypeOfObjectBeingCreated();
Level 4 , Corpus Christi, United States
4 February, 19:23
This was helpful. Thanks JMontrose..
Rolphson S
Level 2 , New York City, United States
2 May 2020, 03:14
I need help asap. I cant figure out what to do.
Massimo Lorenzi
Level 2 , Milan, Italy
21 April 2020, 13:49
perchè non riconosce il metodo person ?
Level 2 , Hammond, United States
12 April 2020, 04:01
I need help, when are you going to go over the lesson first.
Suhas fhadtre
Level 2 , Mumbai, India
28 February 2020, 04:15
Where does a Person come from?