From 19903ae3536255dfa2778846275267605cee9f7e Mon Sep 17 00:00:00 2001 From: Oskar Date: Sun, 18 Aug 2024 21:02:35 +0200 Subject: more exercises, one unfinished --- 4p14.cpp | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 4p14.cpp (limited to '4p14.cpp') diff --git a/4p14.cpp b/4p14.cpp new file mode 100644 index 0000000..84fe963 --- /dev/null +++ b/4p14.cpp @@ -0,0 +1,21 @@ +#include + +/* + * + * 4.14 + * + * + */ + +int main () { + + int i = 0; + + //if(42 = i) {} Not valid, error + int ifs2 = i = 42; + if(ifs2) { // evaluates as true because nonZero == true + std::cout << "..." << std::endl; + } + + return 0; +} -- cgit v1.2.3