MCQOPTIONS
Saved Bookmarks
This section includes 3 Mcqs, each offering curated multiple-choice questions to sharpen your Technical MCQs knowledge and support exam preparation. Choose a topic below to get started.
| 1. |
Which of these can be returned by the operator &? |
| A. | Integer |
| B. | Boolean |
| C. | Character |
| D. | Integer or Boolean |
| E. | |
| Answer» E. | |
| 2. |
class array_output { public static void main(String args[]) { char array_variable [] = new char[10]; for (int i = 0; i < 10; ++i) { array_variable[i] = 'i'; System.out.print(array_variable[i] + """" ); i++; } } } 29.Which of these is long data type literal? |
| A. | 0x99fffL |
| B. | ABCDEFG |
| C. | 0x99fffa |
| D. | 99671246 |
| Answer» B. ABCDEFG | |
| 3. |
Which of the following are legal lines of Java code? ÂÂ1. int w = (int)888.8; ÂÂ2. byte x = (byte)100L; ÂÂ3. long y = (byte)100; ÂÂ4. byte z = (byte)100L; |
| A. | 1 and 2 |
| B. | 2 and 3 |
| C. | 3 and 4 |
| D. | All statements are correct |
| Answer» E. | |