Jun 3, 2025
int variable n with a value of 5.n, use the ampersand (&) before the variable name.int* ptr.n to ptr using ptr = &n.ptr shows it stores the address of n.**), e.g., *ptr.*ptr = new_value.*n now also holds the new value (10).int* pointer must point to an int variable, and similar rules apply for other data types such as float, char, etc.int v; int* ptr2 = &v; *ptr2 = 7;