what is ^ in cpp code example
Example 1: ? in cpp
e = ((a < d) ? (a++) : (a = d))
//advance if else condition
Example 2: c++ .* operator
The .* operator is used to dereference pointers to class members.
Example 3: What is a ~ in c++
class Entity{
public:
~Destructor();
//This is a destructor, which destroys instances and can free up memory.
};
//Source for answer:
// https://stackoverflow.com/questions/1395506/in-c-what-does-a-tilde-before-a-function-name-signify
//Other Sources:
// https://www.ibm.com/support/knowledgecenter/en/ssw_ibm_i_74/rzarg/cplr380.htm
Example 4: x += c++
int main ()
{
int a, b=3;
a = b;
a+=2; // equivalent to a=a+2
cout << a;
}