Take Up Code
32: Static Methods And Data. Always Available.

32: Static Methods And Data. Always Available.

Take Up Code

8:45

About this episode

Declaring methods inside classes is great but what do you do when you want a method you can call anytime? If you are using C++, then just write a method. But if you still want your method in a class or if you are using C# where all methods need to be in classes, then you will need to make your method static. And you can declare static data too. What does that do?

More from Take Up Code

This is the first in a series of comments about the book “How To Code C++ From a Simple Idea To a Game You’ll Understand!” Each episode will be short and focused. You can watch the video versions on Y…

1m