in this scope", when I compile this code,
https://hastebin.com/dutupobowa.cpp
does anybody know the reason?
using namespace std; is missing.
thank you so much
You should use std::ofstream. Never use using namespace std please, it’s super bad practice
Why? It works most of the time
Because explicit namespaces makes code clearer
You pollute the namespaces and then calls to functions with same name but different namespace appear ambiguous
Thx when I put Using namespace std out of the main Function, the problem was solved
Avoid “using namespace std” at all costs
polluting namespaces bad
Because you’re polluting your namespace with everything from the std namespace. Ask most anyone that has been using C++ for any length of time. It’s bad practice.
Обсуждают сегодня