CS B.2.1 - B.2.2

0.0(0)
Studied by 0 people
call kaiCall Kai
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
GameKnowt Play
Card Sorting

1/27

flashcard set

Earn XP

Description and Tags

she a van cleef junkie

Last updated 12:30 AM on 5/12/26
Name
Mastery
Learn
Test
Matching
Spaced
Call with Kai

No analytics yet

Send a link to your students to track their progress

28 Terms

1
New cards

Global Variables

Accessible from anywhere in the program
Declared outside functions, wider scope, and longer lifetime

2
New cards

Local Variables

Accessible only within the declaring function/block
Limited scope and shorter lifetime

3
New cards

Boolean

True or false values

4
New cards

Integer

Whole numbers

5
New cards

String

Sequences of characters

6
New cards

Character

Single characters

7
New cards

Image

Visual representations

8
New cards

Immutablity

cannot change an existing string, you must create a new string with the changes

9
New cards

Local variables are created _____ a function

inside

10
New cards

Global variables are created _____ all functions.

outside

11
New cards

To change a global variable inside a function, you must use the _____ keyword

global

12
New cards

Static Structures

pre defiend, with a set capacity

13
New cards

Dynamic structures

adapt as needed, flexible to accomodate varying amounts of data

14
New cards

Mutable

change contents after creation

15
New cards

Dynamic sizing

grow or shrink automatically as needed

16
New cards

List slicing

extract portions of a list easily

17
New cards

Iterable

Loop through elements with for loops

18
New cards

Nesting

Create lists of lists for complex structures

19
New cards

Stack

A linear data structure that follows the LIFO principle

20
New cards

push(item)

adds an element to the top of the stack

21
New cards

pop()

removes and returns the element at the top of the stack

22
New cards

peek()

returns the element at the top of the stack without removing it

23
New cards

isEmpty()

checks if the stack is empty

24
New cards

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

25
New cards

FIFO

First in first out

26
New cards

enqueue(item)

Adds an element to the rear (end) of the queue

27
New cards

dequeue()

removes and returns the element at the front of the queue

28
New cards

front()

returns the element at the front of the queue without removing it