Probably a dumb question but why does this work?
function isGreaterThan(numberOne, numberTwo){
if(numberOne > numberTwo) {
return true;
} else {
return false;
}
}
console.log(isGreaterThan(4, 6));
and this return an unexpected token error?
function isGreaterThan(numberOne, numberTwo) {
numberOne > numberTwo ? return true : return false;
};
Do ternary conditionals not work with parameter?