Declare 常量练习
填空题 入门
题目
Fill in 空白到 declare 变量 named `pi` 那个 cannot 是 reassigned.
代码
___ pi = 3.14159;
提示
keyword 是短 for '常量'.
解释
const is the correct keyword for a value that should never change, like pi. Using let would allow reassignment, and var is the legacy keyword. The completed line is: const pi = 3.14159;
相关资源
相关课程
- 变量
学习如何变量工作 in programming.
相关速查表
- JavaScript Cheatsheet
快速引用 for JavaScript 变量 keywords.
查阅不认识的术语
新手友好的术语表用大白话解释编程术语——变量、函数、DOM、Promise 等等。
解读错误信息
用大白话解释常见错误——什么意思、为什么发生、如何修复。
动手做项目
通过引导式项目应用所学,含起始代码与解决方案。