Pls Pls read the first answer:
I cannot explain as good as the person answering there so i linked it..Waiting for the banhammer 😭
Although simply speaking heap and stack both are on Virtual memory and therefore can be on RAM or HDD but stack is easily trackable as only the first element(last entered) is used and removed (simultaneously sometimes). However Heap is assigned randomly as needed, so takes more time to track as address needs to be calculated according to demand. This is not done in Stack as the top of stack is always known and does not need to be calculated.
Please verify anyone I do not know how to point to people.