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

JavaScript

Britni Alexander
PLUS
Britni Alexander
Courses Plus Student 11,316 Points

JavaScript Foundations Arrays first code challenge

I am having an issue with the first code challenge for the Arrays section. It says "Set the 'mixture' variable to an array with 3 string elements, 2 numbers and one boolean." I answered as follows: var mixture = ['string', 'string2', 'string3', 4, 5, True]; Am I crazy, or should this work? The error just says "null" Nick Pettit Jim Hoskins

6 Answers

Nick Pettit
STAFF
Nick Pettit
Treehouse Teacher

Don't capitalize True. JavaScript is a case sensitive language. :)

Hi Britni, The boolean value is: true (all lowercase).

  • David

= sign haha

What's wrong with my answer? I keep getting null? var mixture ['hello','world','fight', 1, 2, true];

var mixture = ['string', 'string2', 'string3', 4, 5, true];