Can you declare an override method to be static if the original method is not static?
No. The signature of the virtual method must remain the same. Only the keyword virtual is replaced by the keyword override.
Oops!
Check
Okay!
Check
15
What is the difference between a struct and a class?
Structs are value-type variables and are thus saved on the stack, additional overhead, but faster retrieval. Also structs cannot inherit.
Oops!
Check
Okay!
Check
15
What is a satellite assembly?
When you write a multilingual or multicultural application in .NET, and want to distribute the core application separately from the localized modules,...
Oops!
Check
Okay!
Check
15
What is the C# syntax to catch any possible exception?
a catch block that catches the exception of type System.Exception. You can also omit the parameter data type in this case and just write catch{}.
Oops!
Check
Okay!
Check
heart
Other team wins 10 points!
Oops!
fairy
Take points!
5
10
15
20
25
gift
Win 15 points!
Okay!
lifesaver
Give 10 points!
Oops!
15
If a base class has a number of overloaded constructors, and an inheriting class has a number of overloaded constructors; can you enforce a call from an inherited constructor to a specific base constructor?
Yes, just place a colon, and then keyword base (parameter list to invoke the appropriate constructor) in the overloaded constructor definition inside...
Oops!
Check
Okay!
Check
thief
Give points!
5
10
15
20
25
rocket
Go to first place!
Okay!
fairy
Take points!
5
10
15
20
25
lifesaver
Give 10 points!
Oops!
15
Will a delegate instance prevent its target from being garbage collected?
yes; if the delegate instance itself cant be collected; leads to memory leaks when short-lived object subscribes to an event in a long-lived object us...
Oops!
Check
Okay!
Check
15
How is the DLL Hell problem solved in .NET?
Assembly versioning allows the application to specify not only the library it needs to run (which was available under Win32) but also the version of t...
Oops!
Check
Okay!
Check
15
What is a delegate?
a form of type-safe function pointer used by the .NET Framework.; provides level of indirection; single method interface; delegate instance is an obje...
Oops!
Check
Okay!
Check
15
What does the Dispose() method do with the connection object?
Closes the connection and deletes the object from memory.
Oops!
Check
Okay!
Check
15
When do you absolutely have to declare a class as abstract?
1) When the class itself is inherited from an abstract class2) When at least one of the methods in the class is abstract.
Oops!
Check
Okay!
Check
trap
No points!
Oops!
magnet
Take 15 points!
Okay!
rocket
Go to first place!
Okay!
thief
Give points!
5
10
15
20
25
15
What is the .NET collection class that allows an element to be accessed using a unique key?
HashTable
Oops!
Check
Okay!
Check
seesaw
Swap points!
Oops!
gift
Win 5 points!
Okay!
fairy
Take points!
5
10
15
20
25
thief
Give points!
5
10
15
20
25
15
What are the four things you need in order to use a delegate?
1) delegate type needs to be declared2) there must be a method containing the code to execute3) delegate instance must be created4) delegate instance...