From 063360588ceeb680ff7b992ab859a4b52cd2f0d7 Mon Sep 17 00:00:00 2001 From: brinkqiang Date: Sun, 6 Dec 2020 00:43:42 +0800 Subject: [PATCH] update C++/LeftValCalCulate.cpp. --- C++/LeftValCalCulate.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/C++/LeftValCalCulate.cpp b/C++/LeftValCalCulate.cpp index 25a51f7..170fd3c 100644 --- a/C++/LeftValCalCulate.cpp +++ b/C++/LeftValCalCulate.cpp @@ -1,9 +1,9 @@ -bool TestFunc() +bool TestFunc() { //条件运算时,将作为左值变量放在右边避免出错 int nVal = 12; //编译通过,但会始终返回false - if(2 = nVal) + if(nVal = 2) return false; return true; } \ No newline at end of file -- Gitee