From 5574dc208bef7da15ec4582b504c87dcf8018382 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=88=91=E6=98=AF=E4=BA=BA?= <463625542@qq.com> Date: Thu, 24 Oct 2024 09:08:04 +0000 Subject: [PATCH] =?UTF-8?q?add=20C++/!.cpp.=20=E8=A3=85B=E4=B8=93=E7=94=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: 我是人 <463625542@qq.com> --- C++/!.cpp | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 C++/!.cpp diff --git a/C++/!.cpp b/C++/!.cpp new file mode 100644 index 0000000..47c9200 --- /dev/null +++ b/C++/!.cpp @@ -0,0 +1,11 @@ +#include +using namespace std; +bool b_(bool b) {//取反 + if ((b = !b) && (b_(b))) { + return -114514; + } + return b; +} +int main() { + cout << b_(0) << " " << b_(true) << endl; +} \ No newline at end of file -- Gitee