1/27
she a van cleef junkie
Name | Mastery | Learn | Test | Matching | Spaced | Call with Kai |
|---|
No analytics yet
Send a link to your students to track their progress
Global Variables
Accessible from anywhere in the program
Declared outside functions, wider scope, and longer lifetime
Local Variables
Accessible only within the declaring function/block
Limited scope and shorter lifetime
Boolean
True or false values
Integer
Whole numbers
String
Sequences of characters
Character
Single characters
Image
Visual representations
Immutablity
cannot change an existing string, you must create a new string with the changes
Local variables are created _____ a function
inside
Global variables are created _____ all functions.
outside
To change a global variable inside a function, you must use the _____ keyword
global
Static Structures
pre defiend, with a set capacity
Dynamic structures
adapt as needed, flexible to accomodate varying amounts of data
Mutable
change contents after creation
Dynamic sizing
grow or shrink automatically as needed
List slicing
extract portions of a list easily
Iterable
Loop through elements with for loops
Nesting
Create lists of lists for complex structures
Stack
A linear data structure that follows the LIFO principle
push(item)
adds an element to the top of the stack
pop()
removes and returns the element at the top of the stack
peek()
returns the element at the top of the stack without removing it
isEmpty()
checks if the stack is empty
Abstract Data Type
a conceptual blueprint for a data type. It defines what it does by specficing a behaviour and the operations it supports, but it completely hides how it does it
FIFO
First in first out
enqueue(item)
Adds an element to the rear (end) of the queue
dequeue()
removes and returns the element at the front of the queue
front()
returns the element at the front of the queue without removing it