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 trialIfueko agbontaen
1,928 PointsGoddddddd........why is normalizing not working out???
please I don't understand the error
./Order.java:10: error: unexpected type if (discountCode.indexOf(dollarSign) =-1){ ^ required: variable found: value Note: JavaTester.java uses unchecked or unsafe operations. Note: Recompile with -Xlint: unchecked for details. 1 error
1 Answer
Allan Clark
10,810 PointsFrom the error I would venture to guess that you are looking for the Boolean comparison operator '==' rather than the assignment operator '=' at the following line of code. But forewarning my Java syntax is pretty rusty and I could judge it better with the whole class definition that line of code is in.
if (discountCode.indexOf(dollarSign) == -1)
moneka jani
Courses Plus Student 36 Pointsmoneka jani
Courses Plus Student 36 PointsIfueko agbontaen post your code here...