Issue with Coffee exercise on Java

Can’t see what I am doing wrong, must be bleary eyes.

class Coffee extends Beverage {

public Coffee() {


public void addSugar(2) {

	System.out.println("You added " + cubes + " sugar cubes.");


public static void main(String[] args) {

Coffee myOrder = new Coffee();



Get error: error: illegal start of type
public void addSugar(2) {


1 error

It’s something simple I am sure, just can’t see it.

Thanks in advance

Assuming that you have read

you have to modify your addSugar() Method,
in a Method taking 1 PARAMETER int cubes
then you will be able to call the addSugar() Method providing 1 ARGUMENT int Value 2