MCQOPTIONS
Saved Bookmarks
This section includes 12 Mcqs, each offering curated multiple-choice questions to sharpen your Csharp knowledge and support exam preparation. Choose a topic below to get started.
| 1. |
WHICH_OF_THE_FOLLOWING_IS/ARE_AN_EXCEPTION??$ |
| A. | OutOfBoundException |
| B. | OutOfRangeException |
| C. | OverflowException |
| D. | UnderflowException |
| Answer» B. OutOfRangeException | |
| 2. |
VALUE_40_WILL_BE_ASSIGNED_TO_A[5];?$ |
| A. | The output will be : |
| B. | |
| Answer» C. | |
| 3. |
HOW_MANY_CATCH_BLOCKS_CAN_A_SINGLE_TRY_BLOCK_CAN_HAVE??$ |
| A. | Only 1 |
| B. | Only 2 |
| C. | Maximum 127 |
| D. | As many as required |
| Answer» E. | |
| 4. |
csharp$ |
| A. | java |
| B. | run time error |
| C. | csharp 0 |
| Answer» C. csharp 0 | |
| 5. |
To catch the exceptions ___________________$ |
| A. | An object must be created to catch the exception |
| B. | A variable should be created to catch the exception |
| C. | An array should be created to catch all the exceptions |
| D. | A string have to be created to store the exception |
| Answer» B. A variable should be created to catch the exception | |
| 6. |
Which_among_the_following_is_not_a_method_of_Throwable_class?$ |
| A. | public String getMessage() |
| B. | public Throwable getCause() |
| C. | public Char toString() |
| D. | public void printStackTrace() |
| Answer» D. public void printStackTrace() | |
| 7. |
Multiple_catch_blocks___________________ |
| A. | Are mandatory for each try block |
| B. | Can be combined into a single catch block |
| C. | Are not possible for a try block |
| D. | Can never be associated with a single try block |
| Answer» C. Are not possible for a try block | |
| 8. |
Which of the following is/are not an exception? |
| A. | BadFunctionCallException |
| B. | BadMethodCallException |
| C. | LogicException |
| D. | DomainException |
| Answer» E. | |
| 9. |
There can be a try block without catch block but vice versa is not possible? |
| A. | True |
| B. | False |
| Answer» B. False | |
| 10. |
What is the full form of SPL in Exception Handling? |
| A. | Standard PHP Library |
| B. | Source PHP Library |
| C. | Standard PHP List |
| D. | Source PHP List |
| Answer» B. Source PHP Library | |
| 11. |
When will the else part of try-except-else be executed? |
| A. | always |
| B. | when an exception occurs |
| C. | when no exception occurs |
| D. | when an exception occurs in to except block |
| Answer» D. when an exception occurs in to except block | |
| 12. |
Which among the following is considered as .NET Exception class? |
| A. | Exception |
| B. | StackUnderflow Exception |
| C. | File Found Exception |
| D. | All of the mentioned |
| Answer» C. File Found Exception | |