- script.js
JavaScript
var enoughDevelopers = true;
var techAvailable = false;
var message = 'You cannot start the project';
console.log(message);
Result
Goalscompleted
Let’s describe a compound condition using nested if
.
- Between declaring the
message
variable and logging in the console, addif
with theenoughDevelopers
condition. - Inside the
if
block, add one moreif
with thetechAvailable
condition. - Inside the block of the second
if
, add assignmentmessage = 'You can start the project';
. - Change the value of the
techAvailable
variable totrue
. The value ofmessage
should change.
Comments