VBS教程:运算符-Imp 运算符
发布时间:2016-12-28 来源:查字典编辑
摘要:Imp运算符对两个表达式进行逻辑蕴涵运算。result=expression1Impexpression2参数result任意数值变量。ex...
Imp 运算符
对两个表达式进行逻辑蕴涵运算。
result = expression1
Imp expression2
参数
result
任意数值变量。
expression1
任意表达式。
expression2
任意表达式。
说明
下表显示如何确定
result 的取值:
True | True | True |
True | False | False |
True | Null | Null |
False | True | True |
False | False | True |
False | Null | True |
Null | True | True |
Null | False | Null |
Null | Null | Null |
Imp 运算符执行两个数值表达式相应位的逐位比较,并按下表设置
result 相应位:
0 | 0 | 1 |
0 | 1 | 1 |
1 | 0 | 0 |
1 | 1 | 1 |