This is part codecademy fault and yours… Codecademy’s fault since there is no error there as i can see… Your error there is that you didnt complete the instruction of creating a new instance of the Coffee Object called myOrder. Please paste code if you have further troubles! Hope this helped!
thanks, i did do it.
I don’t know what to do…
class Coffee {
public Coffee() {
}
public void addSugar(int cubes) {
System.out.println("You added " + cubes + " sugar cubes.");
}
Coffee myOrder = new Coffee();
}
public static void main(String[] args) {
}
}
You have written the code outside the main section. Mowe it inside, and it will work.