MCQOPTIONS
Saved Bookmarks
This section includes 4 Mcqs, each offering curated multiple-choice questions to sharpen your C# Questions & Answers Integer Data Types knowledge and support exam preparation. Choose a topic below to get started.
| 1. |
Correct way to assign values to variable c when int a=12, float b=3.5, int c; |
| A. | c = a + b; |
| B. | c = a + int(float(b)); |
| C. | c = a + convert.ToInt32(b); |
| D. | c = int(a + b); |
| Answer» D. c = int(a + b); | |
| 2. |
Correct Declaration of Values to variables a and b ? |
| A. | int a = 32, b = 40.6; |
| B. | int a = 42; b = 40; |
| C. | int a = 32; int b = 40; |
| D. | int a = b = 42; |
| Answer» D. int a = b = 42; | |
| 3. |
Choose .NET class name from which data type UInt is derived? |
| A. | System.Int16 |
| B. | System.UInt32 |
| C. | System.UInt64 |
| D. | System.UInt16 |
| Answer» C. System.UInt64 | |
| 4. |
How many Bytes are stored by Long Data type in C# .net? |
| A. | 8 |
| B. | 4 |
| C. | 2 |
| D. | 1 |
| Answer» B. 4 | |