Write a small C programme to represent the memory layout , i.e memory is having different segments like stack, heep, BSS, data , code, unintialized , intialized. The programme must cover variables in all the segments.
It's not the question of stucking up. i am asking declare a variable per each segment.
For example
int main()
{
int x; -----------------> Stored in Stack segment
}
we know that this variable will store in stack. Similarly i am asking declare variables that must come under each segment. By that there will be a clarity about memory layout.