9/13 error I think

<Below this line, add a link to the EXACT exercise that you are stuck at.>

Hi Guys, I think this number is error,
I have follow the instruction about the call inside the main method,
I did exactly just like the example and the display printed out exactly just like what the it suppose to (based on example), but I cannot finnish this question…

<In what way does your code behave incorrectly? Include ALL error messages.>

“Did you call the bark method on the spike object? Make sure you call it inside of the main method.” - the instruction

“Woof” the display printed out



class Dog {

  int age;
	public Dog(int dogsAge)
  {age = dogsAge;}
  
  public void bark(){System.out.println("Woof");}
  

	public static void main(String[] args) 
  {
   Dog spike = new Dog(6);
   spike.bark();
  	}

}


you missed a !
it would be Woof! // add a ! after Woof

1 Like

Geez, you are right.
Thank you bro!

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.