Question.4
A developer uses an anonymous namespace in a .cpp file:
// helpers.cpp namespace { int internal_counter = 0; void helper_func() { /* ... */ } }
What does the anonymous namespace do?
Select Answer
Makes the contents globally accessible from any file
Makes the contents private to this translation unit -- equivalent to C's static global, but preferred in C++
Creates a randomly named namespace to avoid collisions
Causes a compilation error -- namespaces must have names