(Ad, please don’t block.)

Quizzes » The non-values undefined and null

1. Accessing properties

const result = true.unknownProperty;

What happens?

2. Accessing properties

const result = null.unknownProperty;

What happens?

3. undefined or null?

Given the following JavaScript code.

let foo;
function bar() {}
const baz = (x) => x;

Which of these expressions evaluates to undefined? The remaining ones evaluate to null.


Correct answers: 0 out of 0