Data - more nodes!

0.0(0)
studied byStudied by 0 people
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
Card Sorting

1/27

encourage image

There's no tags or description

Looks like no tags are added yet.

Study Analytics
Name
Mastery
Learn
Test
Matching
Spaced

No study sessions yet.

28 Terms

1
New cards

Data Structure

A systematic way of organizing and accessing data.

2
New cards

Algorithm

A generic step-by-step set of instructions for solving a problem.

3
New cards

Abstract Data Type (ADT)

A theoretical model of a data structure that specifies what operations are allowed but not how they are implemented.

4
New cards

Big O Notation

Describes the worst-case complexity of an algorithm.

5
New cards

O(1)

Constant time – operations take the same time regardless of input size.

6
New cards

O(n)

Linear time – performance scales directly with input size.

7
New cards

O(n²)

Quadratic time – performance scales with the square of input size.

8
New cards

O(log n)

Logarithmic time – performance scales logarithmically with input size.

9
New cards

O(bⁿ)

Exponential time – performance doubles with each additional input.

10
New cards

O(n!)

Factorial time – performance grows extremely fast with input size.

11
New cards

Inheritance

A class can inherit attributes and methods from another class.

12
New cards

Constructor (init)

A special function that initializes an object.

13
New cards

Access Control

Refers to the visibility of variables; public, protected, and private attributes.

14
New cards

Stack

A linear data structure that follows the Last In, First Out (LIFO) principle.

15
New cards

Queue

A linear data structure that follows the First In, First Out (FIFO) principle.

16
New cards

Deque

A data structure that allows insertions and deletions from both the front and back (double-ended queue).

17
New cards

Node

A fundamental building block of linked data structures, consisting of a data field and a reference to the next node.

18
New cards

push(item)

Adds an item to the top of the stack.

19
New cards

pop()

Removes and returns the top item from the stack.

20
New cards

peek()

Returns the top item from the stack without removing it.

21
New cards

enqueue(item)

Adds an item to the back of the queue.

22
New cards

dequeue()

Removes and returns the front item from the queue.

23
New cards

add_front(item)

Adds an item to the front of the deque.

24
New cards

add_rear(item)

Adds an item to the back of the deque.

25
New cards

remove_front()

Removes and returns the front item from the deque.

26
New cards

remove_rear()

Removes and returns the back item from the deque.

27
New cards

self Keyword

Refers to the instance of the class.

28
New cards

str Method

Defines how an object is represented as a string.