Raytheon Interview Question Reverse Engineering and System Developers
0of 0 votesWhat is the output of the following procedure
{
void foo() {
int* a = 0;
char* b = NULL;
printf("%x %x", a, b);
printf("%x %x", *a, b);
printf("%x %x");
}
}
Team: SIGOV
Country: United States
Interview Type: In-Person

this might throw exception:printf("%x %x", *a, b); since both a and b are null pointer, it could throw exception depend on the compiler. a should zero (address)
- Anonymous on June 01, 2012 Edit | Flag Reply