What does the following code do?
void afunction(int *x) { x=new int; *x=12; } int main() { int v=10; afunction(&v); printf(“%d”,v); }
Reveal answer
Fill a bubble to check yourself
What does the following code do?
void afunction(int *x) { x=new int; *x=12; } int main() { int v=10; afunction(&v); printf(“%d”,v); }