07.11.IntroductionToClasses__1_

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

1/22

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.

23 Terms

1
New cards

Abstraction

A general model of the world, focusing on 'what' it is or does rather than 'how' it works.

2
New cards

Abstract Data Type (ADT)

A programmer-defined data type that is an implementation of an abstraction, characterized by its data type and the operations it can perform.

3
New cards

Encapsulation

Combining attributes and methods into a user-defined type to keep everything an object needs to know/do in one place.

4
New cards

Data Hiding

Concealing the internal structure of a class from the user, allowing usage without needing to understand its workings.

5
New cards

Constructor

A special member function of a class that initializes objects of that class; is automatically called when an object is created.

6
New cards

Destructor

A special member function of a class that is automatically called when an object goes out of scope or is explicitly deleted, cleaning up resources.

7
New cards

Operator Overloading

The ability to define custom behavior for operators (like +, -, etc.) for user-defined types.

8
New cards

Copy Constructor

A constructor that initializes a new object as a copy of an existing object of the same class.

9
New cards

Member Function

A function defined inside a class that operates on the class’s data.

10
New cards

Access Specifier (Public/Private)

Keywords that define the accessibility of class members, with public members accessible from anywhere and private members only accessible from within their class.

11
New cards

Friend Function

A function that is not a member of a class but has access to its private and protected members, declared within the class.

12
New cards

Constant Member Function

A member function that cannot modify any member variables and is declared using the 'const' keyword.

13
New cards

Pass-by-Value

A method of passing arguments to functions whereby a copy of the argument is made.

14
New cards

Pass-by-Reference

A method of passing arguments to functions that allows the function to modify the original variable.

15
New cards

Type Conversion Operator

An operator that enables implicit or explicit typecasting of an object from one type to another.

16
New cards

Memberwise Assignment

The basic way to copy the values of one object to another, attribute by attribute.

17
New cards

Object-oriented Programming (OOP)

A programming paradigm based on the concept of 'objects', which contain data and methods relating to that data.

18
New cards

The this pointer

A pointer that refers to the current instance of a class, providing access to its members.

19
New cards

What is the purpose of abstraction in programming?

The purpose of abstraction in programming is to simplify complex systems by focusing on the essential qualities while hiding unnecessary details.

20
New cards

Can you give an example of abstraction in everyday life?

An example of abstraction in everyday life is driving a car, where the driver knows how to operate the vehicle without needing to understand the intricate mechanics of the engine.

21
New cards

How does abstraction benefit software development?

Abstraction benefits software development by making programs easier to manage and allowing developers to work with higher-level concepts instead of getting bogged down by low-level details.

22
New cards

What are some common techniques used to achieve abstraction in programming?

Common techniques to achieve abstraction in programming include defining abstract classes and interfaces.

23
New cards

Why is abstraction considered a fundamental principle of Object-Oriented Programming (OOP)?

Abstraction is considered a fundamental principle of OOP because it allows developers to create models that reflect real-world entities while hiding implementation details.