Answers for "c **"

C
4

pointeurs c

int v;
int *p;
v = 1;
printf("v = %d\n",v);// "V=1"
p = &v;
printf("p = %p\n", p);// 0xA8D532
printf("*p = %d\n", *p);// 1
*p = 10;
printf("v = %d, *p = %d\n", v, *p);// v = 10, *p = 10
Posted by: Guest on October-13-2020
-2

double pointers C++

#include <stdio.h>

int main(void)
{
    int value = 100;
    int *value_ptr = &value;
    int **value_double_ptr = &value_ptr;

    printf("Value: %d\n", value);
    printf("Pointer to value: %d\n", *value_ptr);
    printf("Double pointer to value: %d\n", **value_double_ptr);
}
Posted by: Guest on February-06-2020

Code answers related to "C"

Browse Popular Code Answers by Language