📅  最后修改于: 2022-03-11 15:02:45.554000             🧑  作者: Mango
//Long version
let points = 70;
let result;
if(marks >= 50){
result = 'Pass';
}else{
result = 'Fail';
}
//Shorthand
let points = 70;
let result = marks >= 50 ? 'Pass' : 'Fail';