Pointers in C / C++ [Full Course]

preview_player
Показать описание
Pointers in C and C++ are often challenging to understand. In this course, they will be demystified, allowing you to use pointers more effectively in your code. The concepts you learn in this course apply to both C and C++.

✏️ Course developed by Harsha and Animesh from MyCodeSchool.

⭐️ Course Contents ⭐️
⌨️ (0:00:00) Introduction to pointers in C/C++
⌨️ (0:10:29) Working with pointers
⌨️ (0:22:05) Pointer types, pointer arithmetic, void pointers
⌨️ (0:33:01) Pointers to Pointers in C/C++
⌨️ (0:42:21) Pointers as function arguments - call by reference
⌨️ (0:56:36) Pointers and arrays
⌨️ (1:05:18) Arrays as function arguments
⌨️ (1:18:10) Character arrays and pointers - part 1
⌨️ (1:32:49) Character arrays and pointers - part 2
⌨️ (1:42:49) Pointers and 2-D arrays
⌨️ (1:55:07) Pointers and multidimensional arrays
⌨️ (2:11:50) Pointers and dynamic memory - stack vs heap
⌨️ (2:29:14) Dynamic memory allocation in C - malloc calloc realloc free
⌨️ (2:36:48) Pointers as function returns in C/C++
⌨️ (3:02:01) Function Pointers in C / C++
⌨️ (3:13:57) Function pointers and callbacks
⌨️ (3:29:16) Memory leak in C/C++

⭐️ Special thanks to our Champion supporters! ⭐️
🏆 Loc Do
🏆 Joseph C
🏆 DeezMaster

--

Рекомендации по теме
Комментарии
Автор

I spent decades writing C/C++ code daily, and the best bit of advice anyone ever gave me stuck with me that entire time relating to pointers.
Not sure if it is in this video, as I didn't watch it all ...

When you are reading the declaration of a C/C++ variable, read it right to left in English and the meaning is obvious

e.g. What is a variable defined as ... int * const *
Backward .. it is a Pointer to a constant pointer to an integer

e.g. What is a variable defined as int [] **
Backward .. it is a Pointer to a Pointer to an Array of Integers

Easy :)

Tony-dprl
Автор

Everytime he says thanks for watching, I so desperately want to thank him for teaching. You're a legend, Harsha and you'll never be forgotten 🙏

mohiths
Автор

Note about doing stuff like:
int* p;

It kinda make sense to put the star next to the data type... because it's an "Int pointer" named p. This is fine as long as you declare only one variable per line. Some people like to declare multiple variables at once (I don't recommend doing this but it's doable...). If you do so, only the first variable will be a pointer:

int* p1, p2;
p1 will be a pointer to an integer... But p2 is an integer. This is why you should put the asterisk on the variable name instead:
int *p1, *p2;

turmat
Автор

RIP LEGEND LORD HARSHA. Your contribution to my life is way beyond words.

rohann
Автор

This was created almost 8 years ago! Still not outdated. Best explanation on pointers ever

geekyprogrammer
Автор

Three and a half hour video on just pointers
We are going to take over the world after watching this

immanuelsuleiman
Автор

Thank you, legend. I discovered this video years after your friend and co-teacher passed, but his and your legacy lives on. Thank you for everything. Much love from Nairobi, Kenya. May he smile with the angels.

peternzioki
Автор

I completed this course in a week and enjoyed learning it all. Harsha is the best guru of C and C++ programming and I learned a lot from him. Harsha why so OP. I know that he is no more and he died on June 15 2014 at just age 32 but I know that he made underdogs the winner finally and inspired others to make many more Brilliant Programmers from whole the world and not just INDIA.

ignkaku
Автор

I feel smarter by just clicking on the video.

BinYaseenLife
Автор

I miss this guy, whom I will miss him throughout my life, who helped me passing 3rd semester in University, in Subject Data Structures and
Love you My Code School...
Love you Free Code Camp Org...

indiansoftwareengineer
Автор

This was very helpful, thanks!  
Here are some minor corrections:
- At 0:41:00 : in the discussion of pointer-to-pointer, variable r should hold the address of q (=205), not the value of q (=215).
- At 1:28:00 : print(c2[1]) is only possible via printf(c2 + 1) and this outputs 'e', not 'l'.

MH-ocde
Автор

I must express the greatest possible gratitude for this course. The material is comprehensive, well-thought out and superbly structured. All of my implicit questions (i.e. "I know that I don't understand something, just not know what") are vanishing rapidly, and I haven't even finished the course yet! Thank you, thank you! To listen to this course was probably one of the best decisions I've made as a first year in university.

adomasvensas
Автор

If you're as confused as me after checking the size of A in the sumOfElements function (around 1:15:27) and finding that it yields 8 instead of 4, note that in x64 architectures pointers are assigned 8 bytes. Since A is technically a pointer in that context and that's why you'll get 8 bytes of size

hamzakarabag
Автор

This guy is one of the best instructors I have heard on the web. Speaks very good English and explains things in a very logical, easy to follow manner. Superior instructor. Great job!

floydvanpool
Автор

It's amazing that this is free. These concepts are explained so well and clearly. Thank you!

trevor
Автор

finally I completed it... Pointers topic explained beautifully ...Thanks a lot .
Its Definitely the best explanation available on youtube period.

ronitkumar
Автор

Very clearly explained. I did C programming in 1990 as a part of my university project (I am Mechanical Engineer). I thought that everything is forgotten, but when I watched this video, everything resurfaced as if I had studied all this just yesterday.

NimishP
Автор

Thank you!!! I've been trying to wrap my head around the concept of pointers for the longest time, and this video definitely makes it stick a lot better. When I was taking my programming courses, my instructor kind of just brushed over this topic, but this requires a deeper, more in-depth
approach.

TheVideoChatter
Автор

I have been working as a software engineer in very big semiconductor company and implement functional safe programs. Still i came here to learn something more about pointers and i wasn't disappointed.

chadreshpatel
Автор

I am studying computer science in school now. And we have C language in our syllabus now - definitely YouTube has taught me way more than my school teachers. And now I am proceeding to learn the intermediate of C language by learning the concept of pointer. I have already seen the first chapter of this video and have found it quite useful. Thanks to the person who have explained every thing on that chapter in an easy way.😀

swyamdipta