Exercise 10- console bad


Good afternon.
in the exercise 10, when run the code show the next to error.
Did you creat method run? place it between the bar and main method.

i cheking the code again and next to show the same error.
this is my code.
class Dog {

int age;

public Dog(int dogsAge) {
age = dogsAge;


public void bark() {



public void run(int feet) {

System.out.println("Your dog ran " + feet);


public static void main(String[] args) {

Dog spike = new Dog(5);




please post your code with the link that goes to the lesson and tell us what's your problem


yeah please post your code


even though, you may got the answer from the system. please erase it and apply for step by step. in that way, the program runs perfectly.


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