Exam 12: Separate Compilation and Namespaces
Exam 1: Introduction to Computer and C++ Programming56 Questions
Exam 2: C++ Basics57 Questions
Exam 3: More Flow of Control45 Questions
Exam 4: Procedural Abstraction and Functions That Return a Value53 Questions
Exam 5: Functions for All Sub Tasks54 Questions
Exam 6: Io Streams As an Introduction to Objects and Classes52 Questions
Exam 7: Arrays48 Questions
Exam 8: Strings and Vectors69 Questions
Exam 9: Pointers and Dynamic Arrays39 Questions
Exam 10: Defining Classes61 Questions
Exam 11: Friends, Overloaded Operators, and Arrays in Classes56 Questions
Exam 12: Separate Compilation and Namespaces41 Questions
Exam 13: Pointers and Linked Lists64 Questions
Exam 14: Recursion48 Questions
Exam 15: Inheritance53 Questions
Exam 16: Exception Handling47 Questions
Exam 17: Templates35 Questions
Exam 18: Standard Template Library59 Questions
Select questions type
We use the #ifndef, #define, and #endif
Free
(Multiple Choice)
4.7/5
(37)
Correct Answer:
E
In order to create a namespace called student, you use
Free
(Multiple Choice)
4.9/5
(35)
Correct Answer:
A
In the implementation file for a class name myClass, you have the following statement:
void myClass::display)
{
//code here
}
What does the :: mean here?
Free
(Short Answer)
4.8/5
(35)
Correct Answer:
that display is part of the class myClass
All the code between
#ifndef MYCLASS_H
And
#endf
Is ____________ if MYCLASS_H is defined.
(Multiple Choice)
4.9/5
(44)
In order to hide functions that are defined in the implementation file, they should be part of the ______________ namespace.
(Multiple Choice)
4.8/5
(31)
The statement using namespace std and the statement using std::cin are the same.
(True/False)
4.8/5
(44)
Connecting the application and implementation files together to form an executable file is called
(Multiple Choice)
4.8/5
(41)
In order to make a user-defined ADT available that is defined in the file myfile.h, you would
(Multiple Choice)
4.9/5
(36)
Why will the following code not compile?
Namespace ns1
{
Void print);
Void display1){};
}
Namespace ns2
{
Void print);
Void display2){};
}
Int main)
{
Using namespace ns1;
Using namespace ns2;
Display1);
Display2);
Print);
Return 0;
}
(Multiple Choice)
4.8/5
(40)
Showing 1 - 20 of 41
Filters
- Essay(0)
- Multiple Choice(0)
- Short Answer(0)
- True False(0)
- Matching(0)