Skip to content

Instantly share code, notes, and snippets.

View voxain's full-sized avatar
🌠
Writing Shitcode

voxain voxain

🌠
Writing Shitcode
View GitHub Profile
@voxain
voxain / MemoryStackHeap.md
Created March 10, 2025 07:47
Stack vs Heap Memory Allocation - Copilot

Stack vs Heap Memory Allocation

Memory allocation in programming generally occurs in two areas: the stack and the heap. Both of these memory areas have unique characteristics and are used for different purposes.

Stack Memory Allocation

Characteristics:

  1. Size: The stack is usually smaller in size compared to the heap.
  2. Speed: Stack allocation is faster because it is managed by the CPU and follows a Last In, First Out (LIFO) order.
  3. Lifetime: Variables on the stack have a very short lifetime. They are automatically deallocated when the function that created them returns.
@voxain
voxain / resources.md
Last active April 6, 2023 14:47
Favorite frontend & design resources