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
Ivan Dusanic
Courses Plus Student 307 PointsI get an error in the Workspace. I can't solve it even if I do. Help?
I get this error:
TreeStory.java:27: error: ';' expected
noun.equalsIgnoreCase("jerk"));
^
1 error
even though I think I got it right:
String noun;
boolean isInvalidWord;
do {
noun = console.readLine("Enter a noun: ");
isInvalidWord = noun.equalsIgnoreCase("dork") ||
noun.equalsIgnoreCase("jerk"));
^
3 Answers
Ivan Dusanic
Courses Plus Student 307 PointsIt was a bug, it works now with everything the same.
Steve Hunter
57,712 PointsHi Ivan,
You have an extra closing bracket after "jerk")); - I'll put a comment in your code to illustrate.
Steve.
Steve Hunter
57,712 PointsI've added a caret ( ^ ) underneath your extra bracket.
Ivan Dusanic
Courses Plus Student 307 PointsThank you! I see now, but I wonder why it worked anyway.
Steve Hunter
57,712 PointsI have no idea! Maybe you corrected it. Anyway, as long as you're still going and not stuck.
Ivan Dusanic
Courses Plus Student 307 PointsIvan Dusanic
Courses Plus Student 307 Pointshttps://teamtreehouse.com/workspaces/30735052#