11 lines
306 B
Markdown
11 lines
306 B
Markdown
|
---
|
||
|
title: Initializing Variables with the Assignment Operator
|
||
|
localeTitle: 使用赋值运算符初始化变量
|
||
|
---
|
||
|
## 使用赋值运算符初始化变量
|
||
|
|
||
|
**初始化**变量是为了给它一个初始值。你可以像这样声明和初始化一个变量:
|
||
|
```
|
||
|
var num = 5; // This is equal to 5
|
||
|
|
||
|
```
|