C++ Cheatsheet Cheat Sheet: by Via
C++ Cheatsheet Cheat Sheet: by Via
a%b Modulus can open a new new one. ios::out means /* makes a new object
cheatography.com/technecure/
C++ Cheatsheet Cheat Sheet
by Technecure via cheatography.com/84247/cs/19902/
a<b True if a is less than b int* ptr = mem_address; pointer definition void foo(); // prototype
a <= b True if a is less than or = to b int& ref = other_var; lvalue reference void bar(int i); // prototype w/
params
a>b True if a is greater than b Note: pointers hold a single memory
void foo() { // foo definition
a >= b True if a is greater than or = to b address that you can change while a
std::cout << "Foo function‐
reference holds a single unchangeable
a == b True if a equals b
memory address. \n";
a && b True if a and b are true }
a || b True if a or b are true Pointers void bar(int i) { // bar
cheatography.com/technecure/