PRN221 - Final
1. Which of the following is one of the Behavioral Design Patterns?
a .Facade
b. Abstract Factory
c. Chain of responsibility
d. Bridge: C
2. Which is a definition of a static method?
a. public static MethodA()
b .public void MethodA()
c. private static MethodA()
d. public static void MethodA(): D
3. Which of the following is one of the Gang of Four (GoF) patterns cate-
gories?
a. All of the others
b. Behavioral
c. Creational
d. Structural: A
4. Which of the following keywords meaning access is limited in the same
assembly but not outside the assembly?
a. protected internal
b. public
c .private
d. internal: D
5. Which of the following statements related to Generic Class is True?
a. When creating generic classes, important considerations include: class
type to generalize into type parameters
b. Generic classes encapsulate operations that are not specific to a particular
data type
c. None of the others
d. Generic classes are defined using a type parameter in parentheses after the
class name: B
6. Choose the correct statement related to Generics in C#.
a. A type parameter is a placeholder for a particular type specified when
creating an instance of the generic type
b. Generic means the general form, not specific. In C#, generic means not
specific to a particular data type
c. Generic can be used with classes, interfaces, fields, methods, properties,
and delegates using the out parameter
d. None of the others: B
, PRN221 - Final
7. Which of the following statements related to the Generic Method is True?
a. A method declared with the type parameters for its return type or parameters
is called a generic method
b .Generic methods can only be used to static methods
c .Generic methods can not be defined within non-generic classes
d. None of the others: A
8. For the following statements related to ThreadPool:
Statement 1. The thread pool manages threads efficiently by minimizing the
number of threads that must be created, started, and stopped.
Statement 2. By using the thread pool, we can focus on your business problem
rather than the application's threading infrastructure.
Choose the correct answer :
a. Statement 1 is True and 2 is False
b. Statement 1 is False and 2 is True
c. Statement 1 and 2 are True
d. Statement 1 and 2 are False: C
9. Which of the following keywords is used to override (hidden) an existing
method (must not virtual method) of the base class?
a. new
b. virtual
c. hidden
d. override: A
10. Choose the incorrect statement about the delegate.
a. Delegates are used to invoke methods that have the same signatures
b. Delegates are of reference types
c. A delegate cannot use with event
d. Delegates are type-safe: C
11. Which statement is incorrect about C# language?
a. C# fully supports aspect-oriented programming techniques
b. There is no pointer required in C#
c. C# does support Automatic memory management through the delete key-
word
d. C# fully supports interface-based programming techniques: C
12. Choose the correct statement related to Design Patterns is True?
a. A design pattern provides a general reusable solution for the common
problems that occur in software design
b. A design pattern is a description or template for how to implement an
algorithm that can be used in many different applications
1. Which of the following is one of the Behavioral Design Patterns?
a .Facade
b. Abstract Factory
c. Chain of responsibility
d. Bridge: C
2. Which is a definition of a static method?
a. public static MethodA()
b .public void MethodA()
c. private static MethodA()
d. public static void MethodA(): D
3. Which of the following is one of the Gang of Four (GoF) patterns cate-
gories?
a. All of the others
b. Behavioral
c. Creational
d. Structural: A
4. Which of the following keywords meaning access is limited in the same
assembly but not outside the assembly?
a. protected internal
b. public
c .private
d. internal: D
5. Which of the following statements related to Generic Class is True?
a. When creating generic classes, important considerations include: class
type to generalize into type parameters
b. Generic classes encapsulate operations that are not specific to a particular
data type
c. None of the others
d. Generic classes are defined using a type parameter in parentheses after the
class name: B
6. Choose the correct statement related to Generics in C#.
a. A type parameter is a placeholder for a particular type specified when
creating an instance of the generic type
b. Generic means the general form, not specific. In C#, generic means not
specific to a particular data type
c. Generic can be used with classes, interfaces, fields, methods, properties,
and delegates using the out parameter
d. None of the others: B
, PRN221 - Final
7. Which of the following statements related to the Generic Method is True?
a. A method declared with the type parameters for its return type or parameters
is called a generic method
b .Generic methods can only be used to static methods
c .Generic methods can not be defined within non-generic classes
d. None of the others: A
8. For the following statements related to ThreadPool:
Statement 1. The thread pool manages threads efficiently by minimizing the
number of threads that must be created, started, and stopped.
Statement 2. By using the thread pool, we can focus on your business problem
rather than the application's threading infrastructure.
Choose the correct answer :
a. Statement 1 is True and 2 is False
b. Statement 1 is False and 2 is True
c. Statement 1 and 2 are True
d. Statement 1 and 2 are False: C
9. Which of the following keywords is used to override (hidden) an existing
method (must not virtual method) of the base class?
a. new
b. virtual
c. hidden
d. override: A
10. Choose the incorrect statement about the delegate.
a. Delegates are used to invoke methods that have the same signatures
b. Delegates are of reference types
c. A delegate cannot use with event
d. Delegates are type-safe: C
11. Which statement is incorrect about C# language?
a. C# fully supports aspect-oriented programming techniques
b. There is no pointer required in C#
c. C# does support Automatic memory management through the delete key-
word
d. C# fully supports interface-based programming techniques: C
12. Choose the correct statement related to Design Patterns is True?
a. A design pattern provides a general reusable solution for the common
problems that occur in software design
b. A design pattern is a description or template for how to implement an
algorithm that can be used in many different applications