READ Free Dumps For Microsoft- 70-483
Question ID 16968 | You are developing an application that includes a class named Order. The application will
store a collection of Order objects.
The collection must meet the following requirements:
✑ Internally store a key and a value for each collection item.
✑ Provide objects to iterators in ascending order based on the key.
✑ Ensure that item are accessible by zero-based index or by key.
You need to use a collection type that meets the requirements.
Which collection type should you use?
|
Option A | LinkedList
|
Option B | Queue
|
Option C | Array
|
Option D | HashTable
|
Option E | SortedList
|
Correct Answer | E |
Explanation Explanation: SortedList
- Represents a collection of key/value pairs that are sorted by key based on the associated IComparer implementation. http://msdn.microsoft.com/en-us/library/ms132319.aspx
Question ID 16969 | You are developing an application that uses structured exception handling. The application
includes a class named ExceptionLogger.
The ExceptionLogger class implements a method named LogException by using the
following code segment:
public static void LogException(Exception ex)
You have the following requirements:
✑ Log all exceptions by using the LogException() method of the ExceptionLogger
class.
✑ Rethrow the original exception, including the entire exception stack.
You need to meet the requirements.
Which code segment should you use?
|
Option A | Option A
|
Option B | Option B
|
Option C | Option C
|
Option D | Option D
|
Correct Answer | A |
Explanation Explanation: Once an exception is thrown, part of the information it carries is the stack trace. The stack trace is a list of the method call hierarchy that starts with the method that throws the exception and ends with the method that catches the exception. If an exception is re- thrown by specifying the exception in the throw statement, the stack trace is restarted at the current method and the list of method calls between the original method that threw the exception and the current method is lost. To keep the original stack trace information with the exception, use the throw statement without specifying the exception. http://msdn.microsoft.com/en-us/library/ms182363(v=vs.110).aspx