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!
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
Andrea Evolo
7,496 PointsWhy this count as a sintax error?
var count = 0;
while (count < 26) { document.write("<p>random message</p>"); count ++ 1; // Why the "++" give me an error? } var count = 0;
while (count < 26) { document.write("<p>random message</p>"); count += 1; // and why in this why pass? }
1 Answer

brandon downs
11,577 Pointsyou would need to remove the 1 after the ++
++ is the same as saying +=1