ive been under the idea that you cant do this because b is out of scope after getInt(). Once it returns from that method, b is lost. But this runs fine, prints out 4.Code:#include <stdio.h> int getInt() { int b = 4; return b; } int main(int argc, char *argv[]) { int a; a = getInt(); printf("this is a %d\n", a); return 0; }