Professional Documents
Culture Documents
CSI3120 A2 - Upload
CSI3120 A2 - Upload
300053306
CSI3120 Assignment 2
Question 3:
It is clearly shown that static arrays have the highest compile time, then arrays declared
normally in the stack and finally heaps.This is due to the fact that heap memory is dynamic,
and so constant allocation and deallocation of memory takes time whereas static arrays
have fixed memory in terms of it’s memory size needs to be known at compile time
comparatively to the heap where the memory size is adjusted at runtime.