On step 3 of this project I tried defining the conditional statements with ternary operators, like so:
userInput === ‘rock’ || userInput === ‘paper’ || userInput === ‘scissors’ ? userInput : console.log(‘Error: not a possible choice.’);
They are within an arrow function, as suggested by the exercise.
It logs what you would expect in the case of false; but it does not log userInput in the case of true (just undefined).
When I write the normal if/else statement everything logs as it should.
Thanks for any feedback on this!