9
JS Assignment 4: Control Flow Continued
BrianTran2 (8)

Is anyone doing LambdaSchool JavaScript pretest because I have worked for 40 minutes and I can get question 3 from assignment 4 correct.

You are viewing a single comment. View All
1
ReinierB (6)

@lvillafranca
function exerciseThree(typeOfPizza){
let lovesPizza;
// In this exercise, you will be given a variable, it will be called: typeOfPizza
// You are also given another variable called: lovesPizza;
// Using an if/else statement assign lovesPizza to true if typeOfPizza is 'pepperoni', assign it to false if it is 'olives'
if(typeOfPizza === "pepperoni") {
return true
}
else {
return false
}

// Please write your answer in the line above.
return lovesPizza;
}

this works for me, but they make it seems so hard for no reason. There is no use of using "olives"