Memory Management Flashcards

1
Q

C++ requires manual memory management using new and delete or smart pointers.

A

Memory management

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

manage memory automatically using reference counting

A

Smart pointers
unique_ptr
shared_ptr

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

when allocated memory is not freed

A

You have a MEMORY LEAK

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

How can memory leaks be prevented

A

proper resource management and using smart pointers in C++

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q
A
How well did you know this?
1
Not at all
2
3
4
5
Perfectly