Modern C++ Memory Management: Learn to write good code fast
4.1 (19 ratings)
Instead of using a simple lifetime average, Udemy calculates a course's star rating by considering a number of different factors such as the number of ratings, the age of ratings, and the likelihood of fraudulent ratings.
1,048 students enrolled
Wishlisted Wishlist

Please confirm that you want to add Modern C++ Memory Management: Learn to write good code fast to your Wishlist.

Add to Wishlist

Modern C++ Memory Management: Learn to write good code fast

Using the power of C++11 to efficiently write reliable software
4.1 (19 ratings)
Instead of using a simple lifetime average, Udemy calculates a course's star rating by considering a number of different factors such as the number of ratings, the age of ratings, and the likelihood of fraudulent ratings.
1,048 students enrolled
Created by Mattias Johansson
Last updated 12/2016
English
Current price: $10 Original price: $20 Discount: 50% off
1 day left at this price!
30-Day Money-Back Guarantee
Includes:
  • 2 hours on-demand video
  • 4 Supplemental Resources
  • Full lifetime access
  • Access on mobile and TV
  • Certificate of Completion
What Will I Learn?
  • Write safe and efficient C++ code without memory leaks or memory corruption
  • Use the features of modern C++ to be more productive
View Curriculum
Requirements
  • You should have a basic knowledge of C++.
Description

In this course you will learn how to use the power of modern C++ to write reliable C++ code. C++ is otherwise known to be a difficult language, partly because of all the troubles in keeping track of allocated memory resources. 

By taking this course you will learn how to write better C++ code. Code which is not just easier to read, but also faster to write, faster to debug and faster to run! You will learn the structures and principles used in modern C++ to avoid the headaches of manual memory management completely.

Please enjoy this course. I hope you truly enjoy it!

Regards,

  Mattias


P.S. If you are not completely happy with the contents, you are entitled to a no-questions-asked 30 day 100% money-back guarantee.


What are the requirements?

  • This course assumes that you have a basic knowledge of C++ and know how to write a simple C++ program. You may have used C++ professionally or just taken a course or two.

What am I going to get from this course?

  • You will learn how to avoid the headache of manual memory management by using structures and principles of modern C++.


Who is the target audience?
  • This course is for software developers with a basic knowledge of C++ and who are writing/modifying C++ code.
Students Who Viewed This Course Also Viewed
Curriculum For This Course
Expand All 20 Lectures Collapse All 20 Lectures 01:45:42
+
Introduction and Getting Started
6 Lectures 23:03

Background into how C++ defines its memory. We'll show what the stack and the free store are, how we allocate objects on the stack and the free store and what the difference is for us as developers. 

Memory model introduction
02:53

Understanding what it means to manage the memory while programming in C++. Also listing the most common types of memory errors.

Preview 04:43

Taking the theoretical discussion of what a memory leak is into real world examples in real C++ code. 

Demo: When does memory leaks happen
06:48

Demo: The stack, the free store and the heap
02:57

Stack, free store and the heap
3 questions

Taking the theoretical discussion of what an invalid pointer is into real world examples in real C++ code. 

Demo: Dangling Pointer
03:01
+
Elements of Modern C++
11 Lectures 01:05:33

Introducing the concept of RAII - resource acquisition is initalization. This is not just an awkward acronym, but is an extremely useful concept in C++ and is the basis of modern C++ resource management. 

RAII - Resource Acquisition Is Initialization
05:04


Overview of the smart pointers which exists in standard C++.

Introducing the Smart Pointers
01:49

Introduction to std::unique_ptr, how to create it and how to use it.

Unique pointer
04:22

Demonstration of how to create, use, pass and reset the std::unique_ptr. 

Demo: Unique Pointer
13:55

The Unique Pointer
3 questions

Introduction to std::shared_ptr, how to create it and how to use it. Also why the shared pointer can cause leaks which is exactly what we wanted to avoid!

Shared Pointer
05:09

Demonstration of how to create, use and reset the std::shared_ptr. 

Demo: Shared Pointer
09:49

Shared pointer
3 questions

Introduction to the std::weak_ptr, how it solves the problem with shared_ptr and how to create it.

Weak Pointer
01:04

Demonstration of how to create and use the std::weak_ptr

Demo: Weak Pointer
07:55

Introduction to std::vector which removes the need to allocate arrays using new[]. This shows how the vector works and why this is better than the old arrays. 

Vector
04:06

Demo: using the vector class
08:14

Self check to make sure you understood how to use the std::vector

Vector
6 questions
+
Solving Errors using Modern C++
3 Lectures 17:06

When and why the destructor of your class should be virtual

Why your class may need a virtual destructor
06:39

Demo: solving the dangling pointer
03:22

Demo: Dealing with legacy code
07:05
About the Instructor
Mattias Johansson
4.1 Average rating
19 Reviews
1,048 Students
1 Course
Senior Software Engineer

Hi, I'm Mattias Johansson and I have been working on developing software in C++ for more than 15 years by now. I have always enjoyed diving into solving difficult problems as well as developing computer software.

I live in Göteborg, Sweden, where I have been living since 1999. I moved here to start my studies at Chalmers University. I liked the city and have since then stayed. After I took my M.Sc in Applied Physics, I went on to do a PhD in Optical Remote Sensing. During my studies I implemented the methods and algorithms  which I was trying to develop in C++. Honestly, the code wasn't that great looking, but which research code is? Well, after I finished I joined a great company called Thorlabs where I was working on designing and developing software for data analysis and instrument control. I really learned a lot on how to write good quality software during my more than six years at the company. However, as time goes I felt it was time to move on and I have now joined a small company in town which develops software (in C++ mostly) and algorithms for computer vision and image analysis.