<PLEASE USE THE FOLLOWING TEMPLATE TO HELP YOU CREATE A GREAT POST!>
I have been running through the forums and attempting to find a solution to my issue thus far, but have gotten nowhere really. I am having the error message appear: “Did you call the bark method on the spike object?”
I don’t know where I am going wrong here.
<Below this line, add a link to the EXACT exercise that you are stuck at.>
https://www.codecademy.com/en/courses/learn-java/lessons/object-oriented-programming/exercises/using-methods-1?action=lesson_resume&link_content_target=interstitial_lesson
<In what way does your code behave incorrectly? Include ALL error messages.>
class {
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(1);
spike.bark();
}
}
<do not remove the three backticks above>