Advanced Web Programming MCQs - 4 | 200+ MCQ Questions with Answers


76) Which of the following operator returns the size of a data type in C#?

a) sizeof
b) typeof
c) &</a>
d) *

Ans: a

77) Which of the following access specifier in C# allows a class to expose its member variables and member functions to other functions and objects in the current assembly?

a) Public
b) Private
c) Protected
d) Internal

Ans: d

78) Default access for the members of the class is _______.

a) Private
b) Public
c) Protected
d) Default

Ans: a

79) A class ___________ is a special member function of a class that is executed whenever we create new objects of that class.

a) Variable
b) Constructor
c) Method
d) Function

Ans: b

80) A _________ constructor does not have any parameter

a) inherited
b) parameterised
c) default
d) special

Ans: c

81) The keyword _________implies that only one instance of the member exists for a class.

a) private
b) public
c) Protected
d) static

Ans: d

82) C# supports multiiple inheritance - True / False?

a) TRUE
b) FALSE

Ans: b

83) We can use __________ to implement multiple inheritance in C#

a) interfaces
b) inheritances
c) object
d) constructor

Ans: a

84) When a class is declared _________, it cannot be inherited

a) Private
b) As base
c) sealed
d) as parent

Ans: c

85) A ____________is designed for providing a way to keep one set of names separate from another.

a) structure
b) namespace
c) class
d) interface

Ans: b

86) The ________keyword states that the program is using the names in the given namespace.

a) include
b) library
c) using
d) exclude

Ans: c

87) You can define one namespace inside another namespace. (True / False)

a) TRUE
b) FALSE

Ans: a

88) Value type variables in C# are derived from the class System.ValueType?

a) TRUE
b) FALSE

Ans: a

89) Which of the following converts a type to a double type in C#?

a) ToDecimal
b) ToDouble
c) ToInt16
d) ToInt32

Ans: b

90) Which of the following operator returns the address of an variable in C#?

a) sizeof
b) typeof
c) &
d) *

Ans: c

91) The do not contain the actual data stored in a variable, but they contain a reference to the variables.

a) Value Types
b) Reference value types
c) Reference Types
d) Value Reference types

Ans: c

92) Int, char, float are the examples of __________ data types

a) Reference
b) Value
c) Static
d) Virtual

Ans: b

93) Object is an example of ______________ data type.

a) Reference
b) Value
c) Location
d) Address

Ans: a

94) Inner namespaces can be separated using _________

a) _ (underscore)
b) . (Dot)
c) - (hyphen)
d) -> (Arrow)

Ans: b

95) __________ is mechanism to create multiple methods with the same name and unique signature in the same class

a) Constructor Overloading
b) Method Overriding
c) Method overloading
d) Constructor overriding

Ans: c

96) An ________ is a non-instantiable class which is either partially implemented, or not at all implemented.

a) Static class
b) Sealed class
c) partial class
d) Abstract class

Ans: d

97) A / An _________ in ASP.NET is a collection of single-file or multiple files.
a) Namespace
b) Library
c) assembly
d) dictionary

Ans: c

98) DLL stands for __________

a) data definition library
b) dynamic link library
c) digital library link
d) distributed link library

Ans: b

99) _________ describes the assembly.

a) Library
b) Manifest
c) Metadata
d) MSIL

Ans: b

100) Which programming model should you implement if you want to separate your server-side code from your client-side layout code in a Web page?

a) Single-file model
b) Code-behind model
c) Inline model
d) Client-server model

Ans: b

Previous Page 4 Next