Data Structures Flashcards
(42 cards)
Primitives
int, float, byte, etc. All built from bits.
Basic types used to build software
Primitives
Byte
8 bits, 0-255
Half a byte
Nybble, Hex
Integer types
Short (2B), Int (4B), Long (8B)
Short integer
2 bytes
int Integer
4 bytes
Long integer
8 bytes
Hex
Half-byte, 0-f
Memory location
Pages on physical memory/RAM (frames), or on disk/ROM
Frame
Page in physical memory
Page Replacement steps
Find page on disk, find empty/victim frame, write victim frame to disk if dirty, bring new page into memory, update frame table
FIFO
First-in-first-out, replace oldest page first
LRU
Least-recently-used, replace page that was called on the longest ago
Page vs. Frame
Frame is the storage unit/location in memory, page is the stuff being store
array indexing directions
row / column
Array lookup
Super fast, but modifying the array sucks
Linked Lists
Every node references next node. Lookups are slow, but modifying the list is easy.
Queue
FIFO, built from arrays or lists
Stack
LIFO, built from arrays or lists
Queue terminology
Enqueue, dequeue, remove
Stack terminology
Push, pop, empty
Operational Ceiling
Limit before failure
Limit before failure
Operational Ceiling