| Share this post! | Vote this! |
|
What is a namespace?
A namespace is basically a container for a group of variables/functions etc. I can pretty much guarantee everyone reading this tutorial has already used a namespace in C++ programming. Think of a line that usually comes at the top of a beginner program:
using namespace std;
This is the standard namespace. It's got the definitions of a lot of neat stuff in there.
Why should I use a namespace?
Namespaces are pretty neat. We use them to contain a group of data. Also, it makes it possible to have more than one variable with the same name. One of which is in the namespace, one which isn't. This will be explained later on. more...
A namespace is basically a container for a group of variables/functions etc. I can pretty much guarantee everyone reading this tutorial has already used a namespace in C++ programming. Think of a line that usually comes at the top of a beginner program:
using namespace std;
This is the standard namespace. It's got the definitions of a lot of neat stuff in there.
Why should I use a namespace?
Namespaces are pretty neat. We use them to contain a group of data. Also, it makes it possible to have more than one variable with the same name. One of which is in the namespace, one which isn't. This will be explained later on. more...




0 comments:
Post a Comment