Namespace | Sololearn: Learn to code for FREE!
Neuer Kurs! Jeder Programmierer sollte generative KI lernen!
Kostenlose Lektion ausprobieren
+ 3


What is the use of ' using namespace std '

1st Feb 2017, 12:10 AM
AmierAiman 47
AmierAiman 47 - avatar
2 Antworten
+ 8
It makes your code more simple to read and write. std is a namespace used for c++ objects that are defined in standard libraries that you include at top of your code, when you write #include <iostream> and etc. Without writing "using namespace std;", you would need to write "std::" in front of every c++ standard object. For example, std::cout, std::cin, std::string, std::endl and so on
1st Feb 2017, 1:32 AM
Eligijus Silkartas
Eligijus Silkartas - avatar
- 1
1st Feb 2017, 11:11 AM
AmierAiman 47
AmierAiman 47 - avatar