Q: What does a default header file contain?
Solution: In the header file, we define something that to be manipulated in the program.
Q: setprecision requires which of the following header file?
Solution: The iomanip header file is used to correct the precision of the values.
Q: Which of the following header file does not exist?
Solution: There is no such header filein C++.
Q: Which of the header file must be included to use stringstream?
Solution: stringstream is available under the header filein C++.
Q: Which of the following header files is required for creating and reading data files?
Solution: In this fstream.h header file is used for accessing the files only.
Q: What does a class in C++ holds?
Solution: The classes in C++ encapsulates(i.e. put together) all the data and functions related to them for manipulation.
Q: Which other keywords are also used to declare the class other than class?
Solution: Struct and union take the same definition of class but differs in the access techniques.
Q: The data members and functions of a class in C++ are by default ____________
Solution: By default all the data members and member functions of class are private.
Q: Constructors are used to ____________
Solution: Once the object is declared means, the constructor are also declared by default.
Q: When struct is used instead of the keyword class means, what will happen in the program?
Solution: For structures, by default all the data members and member functions are public.
You Have Score    | /10 |