+ 2

Why using namespace in C++

Namespace with C++

12th Jul 2021, 7:37 PM
Vijayanathan Menakan
Vijayanathan Menakan - avatar
2 Antworten
+ 3
Because you get rid of writing std:: several times in the code.
12th Jul 2021, 9:06 PM
Jan
Jan - avatar
+ 2
Namespace is used to prevent name conflict, and to neatly group things by their purpose or functional relativity (not to be mistaken with functional paradigm). https://en.cppreference.com/w/cpp/language/namespace https://www.w3schools.in/cplusplus-tutorial/namespace/
13th Jul 2021, 4:03 AM
Ipang