Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

Java

Trying to run javac but receive error message

ERROR: ';' expected javac Example.java; ^ ERROR: not a statement javac Example.java; ^

2 Answers

Can you show me your code? It's impossible to help without look at your code.

public class Example {

public static void main(String[] args) {
    // Your amazing code goes here...
    System.out.println("We are a making a new Pez Dispenser.");
    PezDispenser dispenser = new PezDispenser();
    System.out.printf("The dispenser character is %s\n", 
                      dispenser.mCharacterName);
}

}

Nm. I refreshed my workspace and it seems to be working fine now. I hate it when it's something so simple.

Thanks though.

No problem :)