C++

Pointers

// delclaring pointers
int* ptr; // default value 0 when printed
int var; // live in an address 0xA, think of it as empty container
int var = 7; // assignment of 7 into the var container

  • What is a Identity Matrix

    • A square matrix in which all the elements of the principal diagonal are ones and all other elements are zeros. The effect of multiplying a given matrix by an identity matrix is to leave the given matrix unchanged.

  • What is a Pointer:

    • A variable that stores the memory address as its value. A pointer variable points to a data type (like int or string) of the same type, and is created with the * operator. The address of the variable you're working with is assigned to the pointer: — w3schools