Object Oriented Programming

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

1/62

encourage image

There's no tags or description

Looks like no tags are added yet.

Last updated 2:33 PM on 7/11/26
Name
Mastery
Learn
Test
Matching
Spaced
Call with Kai
Chat

No analytics yet

Send a link to your students to track their progress

63 Terms

1
New cards

Object (Definition)

A self-contained unit of code combining data and functionality in a single independent unit.

2
New cards

Object (Runtime & Real-world)

Exists in memory during runtime with own data; e.g., a specific car with its color.

3
New cards

Class

A blueprint or template used to create objects, defining variables and methods.

4
New cards

Encapsulation

Bundling attributes and methods in a class, controlling access using public and private.

5
New cards

Encapsulation (Purpose)

Protects variables from being changed by outside code.

6
New cards

Abstraction

Simplifying complex systems by hiding implementation details and exposing only what is necessary.

7
New cards

Abstraction Example

Driving a car using the accelerator without knowing how the engine accelerates.

8
New cards

Inheritance

When a subclass takes on variables and methods of a parent class.

9
New cards

Inheritance (Purpose & Example)

Ensures code reusability; e.g., SportsCar and Truck inheriting speed from a base Vehicle.

10
New cards

Generalisation

Identifying shared features across specific things and combining them into a reusable solution.

11
New cards

Generalisation Example

Grouping shared traits of lions and tigers into one generalized Animal class.

12
New cards

Polymorphism

Different classes using the exact same method name to perform completely different actions.

13
New cards

Polymorphism Example

A TakeScreenshot class and a MuteMicrophone class both executing their unique tasks via Execute().

14
New cards

Procedural programming

A step by step method that breaks down the program into reusable routines which are called subprograms or functions.

15
New cards

Object oriented programming

A programming paradigm organised around objects and their associated behaviours (methods) rather than sequential logic.

16
New cards

Procedural Programming - Linear Execution

The computer processes code sequentially from the first line down to the last line.

17
New cards

OOP - Blueprints

Classes act as the master blueprints that dictate how every object behaves and handles data.

18
New cards

Procedural Programming - Function Driven

Code is grouped into reusable blocks called procedures, routines, or functions.

19
New cards

Procedural Programming - Design Approach

Uses a top-down design, breaking one big task into smaller steps.

20
New cards

OOP - Object Creation

You can create one master blueprint (class) and instantly pump out hundreds of unique versions (objects).

21
New cards

Procedural Programming - Shared State

Programs rely heavily on global variables that any function can see and change.

22
New cards

OOP - Design Approach

Uses a bottom-up design, making individual pieces first and linking them.

23
New cards

Task definition

A clear explanation of an issue or challenge summing up what you want to change.

24
New cards

Top-down approach

Breaking a complex algorithm down into smaller units called modules.

25
New cards

Bottom-up approach (OOP)

Creating basic classes and objects first, then combining them into larger systems.

26
New cards

Facade pattern

Hides system complexities and provides a single, simplified interface to the client.

27
New cards

Abstraction vs. Facade Pattern

Abstraction hides details of one object; Facade provides a simplified interface to many subsystems.

28
New cards

Agility

The ability of a program to adapt to changing requirements without major changes.

29
New cards

Message-passing

A behaviour in OOP where objects communicate by sending data rather than accessing each other's code.

30
New cards

Message-passing example

Collision is triggered by the player when touched by the lava, it passes a function in the player's object to kill the player

31
New cards

Code optimisation

Modifying code so programs run faster and use less memory.

32
New cards

Python Optimisation: Built-in Functions

Use functions like sum() or max() which run on highly optimized, compiled C code.

33
New cards

Python Optimisation: Generators

Use parentheses () instead of brackets [] to process large datasets one item at a time.

34
New cards

Python Optimisation: String Concatenation

Use "".join(list) instead of looping with += to avoid recreating strings in memory.

35
New cards

Collaborative code development

When a team of programmers work together to build software.

36
New cards

Consistency

When the rules of the program stay the same throughout when writing the code.

37
New cards

Consistency (Formatting)

Standardizing parentheses and spacing so the code looks written by a single person.

38
New cards

Consistency (Naming Conventions)

Developers using intrinsic, meaningful names for their variables.

39
New cards

Consistency (Design Pattern)

Using a standard structure for the overall organization of the code.

40
New cards

Code commenting

Adding notes to sections of your code, explaining its meaning and intent.

41
New cards

Version control

A management system that allows access to a complete history of your process.

42
New cards

Feedback

The ongoing process of getting project feedback to fix mistakes immediately.

43
New cards

Clear and uncluttered mainline

Keeping the main starting section of code short and simple by using subroutines.

44
New cards

One logical task per subroutine

Designing each subroutine to perform only one job for readability and reusability.

45
New cards

Stub

A placeholder dummy code returning hardcoded data used during software testing.

46
New cards

Stub (Dependencies)

Eliminates dependencies, allowing testing before external systems or team code are finished.

47
New cards

Stub (Speed)

Increases speed by returning hardcoded data instantly instead of making slow network calls.

48
New cards

Stub (Predictability)

Guarantees reliable test results by always returning the exact same data.

49
New cards

Stub (Edge Cases)

Simulates rare scenarios like server crashes or network timeouts to test error handling.

50
New cards

Data Structures

Creating specific data formats like lists or dictionaries to process information.

51
New cards

Control Structures

Altering logic flow or data organization using loops or conditional statements.

52
New cards

Data & Control Structures Example

Netflix loading a show list (data structure) and looping to draw thumbnails (control structure).

53
New cards

Ease of maintenance

How easily software can be updated, repaired, and expanded over time.

54
New cards

Regular backup

An automated process of saving code copies to prevent work loss from bugs.

55
New cards

Unit Testing

Testing one small, individual piece of code in isolation to ensure it works correctly.

56
New cards

Subsystem Testing

Integration testing verifying the behavior and interaction between multiple components within a subsystem.

57
New cards

System Testing

Testing the entire completed application from start to finish to validate overall functionality.

58
New cards

White Box Testing

Testing technique requiring full knowledge of internal code to test syntax, logic, or runtime errors.

59
New cards

Black Box Testing

Testing technique where inputs and outputs are known, requiring no coding experience.

60
New cards

Grey Box Testing

Testing technique where the tester has partial knowledge of internal code, structures, or architecture.

61
New cards

Quality Assurance

Ongoing process of testing and checking software to ensure reliability and meet design requirements.

62
New cards

Alpha Testing

Testing performed by developers in a controlled environment to check for core functionality.

63
New cards

Beta Testing

Testing performed by real users in their own environment to gather feedback on reliability.