typedef struct Value{
int id;
char type;
char a;
} Value;
void fooV(Value v){
v.id = 10;
v.type = 'L';
v.a = 'R';
}
int main(void){
Value v;
Pointer p;
int id = 5;
char type = 't';
char a = 'a';
printf("id: %d, type: %c, a: %c \n",id,type,a);
v.a = a;
v.id = id;
v.type = type;
fooV(v);
printf("id: %d, type: %c, a: %c \n",id,type,a);
}
on the fooV call, Local variable value is created ... therefore no data in the caller will be updated But what if I want to return the values from fooV? what should I add to fooV? Thanks