Update Chinese Translation and Fix Indentation (#21977)
* Update Chinese Translation and Fix Indentation * delete the broken image
This commit is contained in:
@ -6,9 +6,9 @@ localeTitle: Python Bool函数
|
||||
|
||||
## 参数
|
||||
|
||||
它需要一个参数, `x` 。使用标准[真值测试程序](https://docs.python.org/3/library/stdtypes.html#truth)转换`x` 。
|
||||
它需要一个参数`x` 。使用标准[真值测试程序](https://docs.python.org/3/library/stdtypes.html#truth)转换`x` 。
|
||||
|
||||
## 回报价值
|
||||
## 返回值
|
||||
|
||||
如果`x`为false或省略,则返回`False` ;否则返回`True` 。
|
||||
|
||||
@ -27,6 +27,6 @@ print(bool(4 > 2)) # Returns True as 4 is greater than 2
|
||||
print(bool([])) # Returns False as list is empty and equal to 0 according to truth value testing
|
||||
```
|
||||
|
||||
 [运行代码](https://repl.it/CVCS/2)
|
||||
[运行代码](https://repl.it/CVCS/2)
|
||||
|
||||
[官方文件](https://docs.python.org/3/library/functions.html#bool)
|
Reference in New Issue
Block a user