5 Written Questions
5 Matching Questions
- What is a satellite assembly?
- How is the DLL Hell problem solved in .NET?
- Whats the advantage of using System.Text.StringBuilder over System.String?
- Why are there five tracing levels in System.Diagnostics.TraceSwitcher?
- Can you allow a class to be inherited, but prevent a method from being overridden?
- a The tracing dumps can be quite verbose. For applications that are constantly running, you run the risk of overloading the machine and the hard-drive. Five levels range from None to Verbose, allowing you to fine-tune tracing activities.
- b 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 the assembly.
- c StringBuilder is more efficient in cases where there is a large amount of string manipulation. Strings are immutable so each time a string is changed, a new instance is created in memory.
- d Yes. Just leave the class public and make the method sealed.
- e When you write a multilingual or multi-cultural application in .NET, and want to distribute the core application separately from the localized modules, the localized assemblies that modify the core application are called satellite assemblies.
5 Multiple Choice Questions
- Yes. The keyword "sealed" will prevent the class from being inherited.
- 1) CorDBG - command-line debugger. You must compile the original C# file using the /debug switch to use CorDBG. 2) DbgCLR - graphic debugger. Visual Studio .NET uses the DbgCLR.
- Windows Authentication is trusted because the username and password are checked with Active Directory. The SQL Server authentication is untrusted, since SQL Server is the only verifier participating in the transaction.
- Yes, .NET supports multiple interface inheritance.
5 True/False Questions
What does the keyword "virtual" declare for a method or property? → The method or property can be overridden and most importantly, the run-time type of the object determines which method is to be invoked.
What is the wildcard character in SQL? → Interfaces, like classes, define a set of properties, methods, and events. But unlike classes, interfaces do not provide implementation. They are implemented by classes, and defined as separate entities from classes.
What does the term immutable mean? → The data value may not be changed. Note: The variable value may be changed, but the original immutable data value was discarded and a new data value was created in memory.
Explain how a finally block works. → A try/catch block can be optionally followed by a finally block that will be executed whether or not the code in the try or catch blocks executes successfully.
How do you generate documentation from the C# file commented properly with a command-line compiler? → Compile it with the /doc switch.