python中有一种特殊的语法
a=10
b= 20
1 and a or b
这个时候我们看的值是 1 and a到底是 true还是false,如果是true ,那么最终的结果就是a
所以这个的结果为 10
同样的
0 and a or b
结果为20
Latest posts by Zhiming Zhang (see all)
- istio Ingress Gateways - 十一月 25, 2020
- Istio VirtualService - 十一月 23, 2020
- istio 组件 - 十一月 18, 2020