我对有关!!运算符的某些C ++代码有问题。它给了我意外的结果,我不明白为什么:
!!
int x=-12; x=!!x; print("value=",x);
此输出为1。但是我不知道怎么做。谁能解释这个模棱两可的结果?
1
c++
c++ ×1