retagged by
2,222 views
0 votes
0 votes
TRUE/FALSE

1.STATIC STORAGE ALLOCATION  DOES NOT SUPPORT DYNAMIC DATA  STRUCTURE.

2.STACK STORAGE ALLOCATION  DOES NOT SUPPORT DYNAMIC DATA  STRUCTURE.
retagged by

1 Answer

1 votes
1 votes

static data structure is like array ...

and dyanmic like heap...

so static data structure is like once we fixed it we cant change its size means we know everything in advance  ....

whereas dyanmic we can change its size means grow shrink now understand their concepts with help of their memories i think main concept is of memories ......

Static Memory: It is allocated during compiletime of a program, once its data type is fixed it cannot be changed, it occupies space in hard disk before runtime, when the program is running one cannot free the memory which is assigned to the variable even if it variable is not used ever. Array is a classic example of static Memory, once we declare an array of a particular size that amount of memory will be reserved and in contagious memory location and that space will be reserved throughout entire run of program 

Dynamic memory: As the name suggests it is dynamic in nature, it can be created, assigned and destroyed at any instance of time, one disadvantage of it is that it assigns random memory location each time for the new variable. At any point, memory assigned to it can be free, the memory assignment is done at runtime. A linked list is a classic example of it one can keep adding nodes in the system

edited by

Related questions

1 votes
1 votes
1 answer
1
MIRIYALA JEEVAN KUMA asked Jan 21, 2018
642 views
The drawback with stack storage allocation is when the function completes its execution its result cannot be used some point of time later.Can you please explain this bri...
0 votes
0 votes
1 answer
2
Dexter asked Apr 12, 2016
1,082 views
Consider the following sentences :1. Static allocation binding do not change at run time2. Heap Allocation allocate and deallocate at run timeWhich of the above is true ?...
0 votes
0 votes
0 answers
3
0 votes
0 votes
0 answers
4
nbhatt asked Jan 12, 2023
440 views