我正在尝试在vscode中运行此代码,但显示错误
代码:
let age = 6
// If 7 or under print message about child pricing
if (age <= 7) {
console.log('You will get a child discount!')
}
// If 65 or older print message about senior discount
if (age >= 65) {
console.log('You will get a senior discount!')
}
答案 0 :(得分:0)
您将必须这样做:
cd basics
node ifstatements.js
你很好。