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

Help with an error in Java

Hi all, this is the code I'm working on in school and cannot figure out how to resolve the error. I think there's a { missing but I cannot pinpoint it. Please let me know what you guys see here if possible. Thanks so much!

package central;

{ } }
import javax.swing.JFrame;

public class FaceViewer { public static void main(String[] args) {
JFrame frame = new JFrame(); frame.setSize(150, 250); frame.setTitle("An Alien Face"); frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);

  FaceComponent component = new FaceComponent();
  frame.add(component);

  frame.setVisible(true);        
}

}