I would like to know if it is possible to in the first C program:
- Allocate and declare an int to the value of
5
in memory - Print out the address of the variable (eg:
0x7ffee6a98ad8
) - Terminate
And then in a second C program, after the first has completely finished executing:
- Read in the data that was previously declared at address
0x7ffee6a98ad8
- Print the correct value of
5
Is this a possibility in C?
If so, how would one go about accomplishing such a task?
I am using Linux, if that matters.