Where did i go wrong?


#1



https://www.codecademy.com/en/courses/learn-java/lessons/object-oriented-programming/exercises/classes-constructor-parameters?action=lesson_resume&link_content_target=interstitial_lesson


im not getting an error message. it is saying i did not "add the dogsAge parameter to the constructor".


class Dog {
  
		int age;

		public Dog (int dogsAge) {
      
      	age = dogsAge;
      
    }
  
			
	public static void main(String[] args) {

	}

}


#2

Did you try taking out the space in-between public Dog and (int dogsAge)?


#3

yes, it did not help :frowning:


#4

I'm having issue and I've been stuck in that exercise.

Did you figure it out?


#5

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