Identify the correct sentence regarding inequality between reference and pointer.
1.we can not create the array of reference
2.we can create the Array of reference
3.we can use reference to reference
4.we can use variable
Posted Date:-2021-02-19 19:07:02
Pick the correct statement about references in C++.
1. References stores the address of variables
2.References and variables both have the same address
3.References use dereferencing operator(*) to access the value of variable its referencing
4.References were also available in C
Posted Date:-2021-02-19 19:07:02
Pick the correct statement about references.
1.References can be assigned value NULL
2. References once assigned cannot be changed to refer another variable
3. Reference should not be initialized when created
4.Reference is the same as pointers
Posted Date:-2021-02-19 19:07:02
Pick the incorrect statement for namespaces in C++.
1.Namespace declarations are always global scope
2.Keyword namespace is used at the starting of a namespace definition
3.Namespace has access specifiers like private or public
4. Namespace definitions can be nested
Posted Date:-2021-02-19 19:07:02
What is the meaning of the following declaration? int(*ptr[5])();
1.ptr is pointer to function
2.ptr is array of pointer to function
3. ptr is pointer to such function which return type is array
4.ptr is pointer to array of function
Posted Date:-2021-02-19 19:07:02
which keyword is used to define the macros in c++?
1.macro
2.define
3.#define
4.#macro
Posted Date:-2021-02-19 19:07:02
Which operator is used for accessing a member of namespace?
1.:
2.::
3.->
4..
Posted Date:-2021-02-19 19:07:02
How a reference is different from a pointer?
1.A reference cannot be null
2.A reference once established cannot be changed
3.The reference doesn’t need an explicit dereferencing mechanism
4. All of the mentioned
Posted Date:-2021-02-19 19:07:02
How many types do functions fall depends on modularization?
1.1
2.2
3.3
4.4
Posted Date:-2021-02-19 19:07:02
How many types of linkages are there in C++?
1.1
2.2
3.3
4.4
Posted Date:-2021-02-19 19:07:02
How many types of macros are there in c++?
1.1
2.2
3.3
4.4
Posted Date:-2021-02-19 19:07:02
How many types of modularization are there in c++?
1.4
2.3
3.1
4.2
Posted Date:-2021-02-19 19:07:02
Identify the correct statement.
1.c++ does not have built-in interfaces
2.c++ does have built-in interfaces
3.c++ have no concept of interfaces
4. c++ does have built-in interfaces & classes
Posted Date:-2021-02-19 19:07:02
Identify the correct statement.
1.Namespace is used to group class objects and functions
2. Namespace is used to mark the beginning of the program
3.A namespace is used to separate the class objects
4.Namespace is used to mark the beginning & end of the program
Posted Date:-2021-02-19 19:07:02
Identify the incorrect statement.
1.Reference is the alternate name of the object
2.A reference value once defined can be reassigned
3.A reference value once defined cannot be reassigned
4.Reference is the alternate name of the variable
Posted Date:-2021-02-19 19:07:02
Which value can we not assign to reference?
1.integer
2.floating
3.unsigned
4.null
Posted Date:-2021-02-19 19:07:02
To use internal linkage we have to use which keyword?
1.static
2.extern
3.static or extern
4.public
Posted Date:-2021-02-19 19:07:02
To where does the program control transfers when the exception is arisen?
1.catch
2.handlers
3.throw
4.try
Posted Date:-2021-02-19 19:07:02
To which does the function pointer point to?
1.variable
2.constants
3.function
4.absolute variables
Posted Date:-2021-02-19 19:07:02
What are the references in C++?
1.An alternative name for already existing variables
2.A pointer to a variable
3.A new type of variables
4.A new type of constant variable
Posted Date:-2021-02-19 19:07:02
What does a reference provide?
1.Alternate name for the class
2.Alternate name for the variable
3.Alternate name for the pointer
4.Alternate name for the object
Posted Date:-2021-02-19 19:07:02
What does the client module import?
1.macro
2.records
3.interface
4.instance
Posted Date:-2021-02-19 19:07:02
What is similar to the interface in c++?
1.methods
2. instance of a class
3. pure abstract class
4.methods & instance of a class
Posted Date:-2021-02-19 19:07:02
What is the ability to group some lines of code that can be included? in the program?
1.specific task
2. program control
3.modularization
4.macros
Posted Date:-2021-02-19 19:07:02
What is the correct syntax of defining a namespace?
1.namespace name{}
2.Namespace name{};
3.namespace name{};
4.typedef namespace name{} NAME
Posted Date:-2021-02-19 19:07:02
What is the default calling convention for a compiler in c++?
1.__cdecl
2.__stdcall
3.__pascal
4.__fastcall
Posted Date:-2021-02-19 19:07:02
What is the default type of linkage that is available for identifiers?
1.internal
2.external
3. no linkage
4.single linkage
Posted Date:-2021-02-19 19:07:02
What is the difference between references and pointers?
1.References are an alias for a variable whereas pointer stores the address of a variable
2.References and pointers are similar
3.References stores address of variables whereas pointer points to variables
4.Pointers are an alias for a variable whereas references stores the address of a variable
Posted Date:-2021-02-19 19:07:02
What is the general syntax for accessing the namespace variable?
1.namespace::operator
2.namespaceoperator
3.namespace#operator
4.namespace$operator
Posted Date:-2021-02-19 19:07:02
What is the mandatory part to present in function pointers?
1.&
2.return values
3.data types
4.$
Posted Date:-2021-02-19 19:07:02
What is the mandatory preprocessor directive for c++?
1. #define <iostream>
2.#include <iostream>
3. #undef <iostream>
4.#macro <iostream>
Posted Date:-2021-02-19 19:07:02
What is the other name of the macro?
1.scripted directive
2.executed directive
3.link directive
4.executed & link directive
Posted Date:-2021-02-19 19:07:02
What is the use of Namespace?
1.To encapsulate the data
2. To structure a program into logical units
3.Encapsulate the data & structure a program into logical units
4. It is used to mark the beginning of the program
Posted Date:-2021-02-19 19:07:02
What will happen when the exception is not caught in the program?
1.error
2.program will execute
3.block of that code will not execute
4.program will execute & displays wrong output
Posted Date:-2021-02-19 19:07:02
What will happen when the handler is not found for an exception?
1.calls the standard library function terminate()
2. raise an error
3.executes the remaining block
4.raise an error and executes the remaining block
Posted Date:-2021-02-19 19:07:02
What will we not do with function pointers?
1.allocation of memory
2.deallocation of memory
3.both allocation & deallocation of memory
4.finds memory status
Posted Date:-2021-02-19 19:07:02
Which keyword is used to access the variable in the namespace?
1.using
2.dynamic
3.const
4.static
Posted Date:-2021-02-19 19:07:02
Which keyword is used to check exception in the block of code?
1.catch
2.throw
3.try
4.handlers
Posted Date:-2021-02-19 19:07:02
which of the following can be passed in function pointers?
1.variables
2. data types
3.functions
4.objects
Posted Date:-2021-02-19 19:07:02
Which of the following function must use reference.
1.Assignment operator function
2.Copy Constructor
3.Destructor
4.Parameterized constructor
Posted Date:-2021-02-19 19:07:02
Which of the following implements the module in the program?
1.macro
2.header files
3.macro & header files
4.interfaces
Posted Date:-2021-02-19 19:07:02
Which of the following is incorrect?
1.References cannot be NULL
2. A reference must be initialized when declared
3.Once a reference is declared it cannot be modified later to reference another object i.e. it cannot be reset
4.References cannot refer to a constant value
Posted Date:-2021-02-19 19:07:02
which of the following is used to implement the c++ interfaces?
1.absolute variables
2.abstract classes
3.constant variables
4.default variables
Posted Date:-2021-02-19 19:07:02
Which of the following operator is used while declaring references?
1.*
2.&
3.^
4.>
Posted Date:-2021-02-19 19:07:02
Which of the following statement(s) is/are correct?
1.operator is used to declare a reference
2.A reference variable defined to refer a particular variable can refer to any other variable also
3.References must always be initialized inside classes
4.A variable can have more than one references
Posted Date:-2021-02-19 19:07:02
Which one is used to refer to program elements in any translation units?
1.internal linkage
2.external linkage
3. no linkage
4.internal & external linkage
Posted Date:-2021-02-19 19:07:02
Which operator is used to signify the namespace?
1.conditional operator
2.ternary operator
3. scope operator
4. bitwise operator
Posted Date:-2021-02-19 19:07:02
Which reference modifier is used to define the reference variable?
1.&
2.$
3.#
4.@
Posted Date:-2021-02-19 19:07:02
Which symbol is used to declare the preprocessor directives?
1.#
2.$
3.*
4.^
Posted Date:-2021-02-19 19:07:02