Quiz
OOP C++ - Basics
Crie uma conta grátis para terminar este quiz
Salve seu progresso e veja sua nota final.
Já tem uma conta? Inicie sessão
Perguntas do quiz (46)
1Information Hiding can also be termed as
- AData hiding
- BEncapsulation
- CInheritance
2The process by which one object can acquire the properties of another object
- AEncapsulation
- BInheritance
- CPolymorphism
3Method with the same name or different return type and difference in the parameters either in number or type is known as
- AFunction overloading
- BCompile Time Overloading
4Which of the following is not a part of OOP?
- AType checking
- BMultitasking
- CPolymorphism
- D
Information hiding
5Keyword which is used to access the method or member variables from the superclass
- ASuper
- BUsing
- CIs_a
- DHas_a
6What modifiers are allowed for methods in an Interface (choose one or more answers)
- APublic
- BPrivate
- CAbstract
7Two or more methods with same name in the same class with different arguments is called as
- AMethod overriding
- BMethod overloading
8Pick the term that relates to polymorphism
- ADynamic binding
- BDynamic allocation
- CStatic typing
- DStatic allocation
9When deriving from a private base class, the public, protected and private members of the base class become private members of the derived class.
- AVerdadeiro
- BFalso
10When sub class declares a method that has the same type arguments as a method declared by one of its superclass,it is termed as
- AMethod overriding
- BMethod overloading
- COperator overloading
- DOperator overriding
11An _______ cannot provide any code at all,can provide only the signature.
- AAbstract class
- BInterface
12 Can objects of abstract classes be instantiated
- AVerdadeiro
- BFalso
13Constructors are used to
- ATo build a user interface
- BFree memory.
- CInitialize a newly created object
- DTo create a sub class
14An object that has more than one form is referred to as
- AInheritance
- BInterface
- CAbstract class
- DPolymorphism
15 Main method can be overriden
- AVerdadeiro
- BFalso
16An object is
- AOne instance of a class
- BAnother word for a class
- CA class with static methods
- DA method that accesses class attributes
17Access to private data or private methods is
- ARestricted to methods of the same class
- BRestricted to methods of other classes
- CAvailable to methods of the same class and other classes
- DNot an issue because the program will not compile
- ARestricted to methods of the same class
18Inheritance is the process of
- AUsing classes in the established standard C++ Language library
- BUsing features from an existing class
- CCombining data and the methods, which process the data, inside the same module.
- DDividing a program into multiple related files for each class in the program.
19In an object-oriented programming language __________ is used to refer to one of two related but distinct notions, and sometimes to the combination thereof:
A language mechanism for restricting access to some of the object's components.
A language construct that facilitates the bundling of data with the methods operating on that data.- AInheritance
- BAbstraction
- CEncapsulation
- DPolymorphism
20All object-oriented programming languages must have the 3 following features:
- AAssociation, inheritance, objects
- BInheritance, polymorphism, encapsulation
- CInheritance, association, encapsulation
- DState, behavior, identity
- EClasses, subclasses, superclasses
21 Which are considered formal business concepts ready for software modeling in UML?
- ARunning, walking, crawling
- BAccount, room, paper
- CSlicing, dicing, chopping
- DDrive, steer, unload
- ERecording, bank account, car
22One or more function that has different number of argument or different type of argument but all have same return type is called as
- AFunction overloading
- BFunction overridding
- CEncapsulation
- DInheritance
23To call a base class constructor in a derived class, is it needed to call the base class initializer.
- AVerdadeiro
- BFalso
24A system that translates domain names to IP addressesis referred to as
- ADomain Name System
- BISP
25Mention two forms of polymorphism
- AOperator overloading
- BFunction overloading
- CMethod overriding
- DMethod overloading
26Static methods cannot be accessed directly from the class level
- AVerdadeiro
- BFalso
27You can use C++ as a procedural, as well as an object-oriented, language
- AVerdadeiro
- BFalso
28A default catch block catches
- Aall thrown objects
- Bno thrown objects
- Cany thrown object that has not been caught by an earlier catch block
- Dall thrown objects that have been caught by an earlier catch block
29Adding a derived class to a base class requires fundamental changes to the base class
- AVerdadeiro
- BFalso
30Format flags may be combined using
- Athe bitwise OR operator (|)
- Bthe logical OR operator (||)
- Cthe bitwise AND operator (&
- Dthe logical AND operator (&&)
31The use of the break statement in a switch statement is
- Aoptional
- Bcompulsory
- Cnot allowed. It gives an error message
- Dto check an error
- ENone of the above
32To expose a data member to the program, you must declare the data member in the _____ section of the class
- Acommon
- Bexposed
- Cpublic
- Dunrestricted
- Euser
33Which of the following are valid characters for a numeric literal constant?
- Aa comma
- Ba dollar sign ($)
- Ca percent sign (%)
- Da space
- ENone of the above
34A function that changes the state of the cout object is called a(n) _____
- Amember
- Badjuster
- Cmanipulator
- Doperator
35 Evaluate the following expression: 3 >6&&7>4
- AVerdadeiro
- BFalso
36A C++ program contains a function with the header int function(double d, char c). Which of the following function headers could be used within the same program?
- Achar function(double d, char c)
- B int function(int d, char c)
- Cboth (a) and (b)
- Dneither (a) nor (b)
37
When the compiler cannot differentiate between two overloaded constructors, they are called- Aoverloaded
- Bdestructed
- Cambiguous
- Ddubious
38Some Streams work with input, and some with output
- AVerdadeiro
- BFalso
39If you design a class that needs special initialization tasks, you will want to design a(n) _____
- Ahousekeeping routine
- Binitializer
- Cconstructor
- Dcompiler
40Which type of statement does not occur in computer programs?
- Asequence
- Bloop
- Cdenial
- Dselection
41The newline character is always included between
- Apair of parentheses
- Bpair of curly braces
- Ccontrol string
- D&
- ENone of the above
42To be called object-oriented, a programming language must allow
- Afunctions that return only a single value
- B#include files
- Cinheritance
- DAll of the above
43A function that returns no values to the program that calls it is _____
- Anot allowed in C++
- Btype void
- Ctype empty
- Dtype barren
44The keyword used to define a structure is _____
- Astru
- Bstt
- Cstruct
- Dstructure
45If container classes are carefully constructed, then these tools are available to work with structures that are not ______
- Avalid without container classes
- Bprogrammer-defined
- Ctype-specific
- Dpublic
46Header files often have the file extension _____
- A.H
- B.HE
- C.HEA
- D.HEAD
Informações
- Descrição
- Quiz sobre OOP C++ - Basics, criado por iskraarsova em 15-04-2015.
- Autor
- iskraarsova
- Idioma
- English
- Visualizações
- 8
- Avaliação
- Ainda sem avaliações Avalie este quiz