C++ Programming Question:

Define namespace in C++?

Tweet Share WhatsApp

Answer:

It is a feature in C++ to minimize name collisions in the global name space. This namespace keyword assigns a distinct name to a library that allows other libraries to use the same identifier names without creating any name collisions. Furthermore, the compiler uses the namespace signature for differentiating the definitions.

Download C++ Programming PDF Read All 120 C++ Programming Questions
Previous QuestionNext Question
When does a name clash occur in C++?What is the use of ‘using’ declaration in C++?