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
Chris Chagnon
4,947 PointsI don't get this quiz question? Finish the code below to create a variable named shipsLeft containing the number 10.
Finish the code below to create a variable named shipsLeft containing the number 10.
________ shipsLeft = 10;
What do I do?
3 Answers
Thas Eagans
Courses Plus Student 2,533 PointsIn JS, u use the keyword var to create variables.
var shipsLeft = 10;
</TREagans>
Chris Chagnon
4,947 PointsFill in the blank below. Bummer! Unfortunately, that answer is incorrect. Skip Quiz Review Video Next Question Finish the code below to create a variable named shipsLeft containing the number 10.
var shipsLeft = 10;
Cora Weiss
Courses Plus Student 1,271 Pointsi wrote the same thing and it worked
Thas Eagans
Courses Plus Student 2,533 PointsHmmm, that's weird.
</TREagans>
Chris Chagnon
4,947 PointsChris Chagnon
4,947 PointsIt didn't work. Fill in the blank below. Bummer! Unfortunately, that answer is incorrect. Skip Quiz Review Video Next Question Finish the code below to create a variable named shipsLeft containing the number 10.
var shipsLeft = 10;
Gabriela Miranda
435 PointsGabriela Miranda
435 PointsSometimes the answer is so on our face that we ca not belive. Thanks Thas Eagans To create a create a variable we must put var like they said in the class.