+ 2

stack in c++/java

i see many programing languages are stack based such is c/c++, java, js, and so on. i know definition of stack in data structures. but i do not know exactly what its mean in memory situations. why its size is limit? and why c and others is stack based while assembly and machine bytecodes are register based?

20th Aug 2021, 3:32 PM
Mehran
Mehran - avatar
3 Answers
+ 1
Martin Taylor https://code.sololearn.com/c8pBh3U8tPKO/?ref=app see this code. can you explain my mistakes?!
20th Aug 2021, 4:50 PM
Mehran
Mehran - avatar
+ 1
Martin Taylor if system be 64bit(in my test system is 64bit) and program store int value forward to top of memory, third int placed in correct address and return address stored before it.
20th Aug 2021, 5:01 PM
Mehran
Mehran - avatar
+ 1
Martin Taylor are you forget to answer me?!
21st Aug 2021, 11:22 AM
Mehran
Mehran - avatar