click below
click below
Normal Size Small Size show me how
JAVA
| Question | Answer |
|---|---|
| A file that is compiled to produce bytecode file | class file (java source code ) correct sa canva |
| A single-line comment starts with /* | false |
| long has a value that ranges from -32768 to 32767 | false |
| An IDE doesn't have various tools to simplify the construction of a GUI. | false |
| byte has a maximum value of 128 | false |
| System is a class | true |
| A function in C language is similar to what in Java language? | Method |
| nextBoolean() reads a boolean value from the user. | true |
| An IDE consists of a source code editor | true |
| An IDE doesn't have debugger | false |
| A Netbeans feature that is used to write, test, and debug applications for the Java Micro Edition platform (J2ME) technology-enabled mobile devices | NetBeans Mobility Pack |
| Netbeans started as a student project called Selfie | false |
| An IDE doesn't have build-automation tools. | false |
| The goal in developing netbeans was to write a Delphi- like Java IDE in Java for the first time. | true |
| Netbeans Matisse supports internationalization, and industrial look-and-feel rules, which is very important for large scale application meant to be spread world wide. | true |
| double data type has a width of 8 in bytes. | true |
| Java Bytecode File Extension name is .java. | False |
| "\tab" is an escape character for tab. | false |
| int has a width of 4 bytes | true |
| A feature of java that means Java technology is designed to support applications that will be deployed into heterogeneous network environments | Architecture neutral and portable |
| In standalone Java applications, which method is mandatory? | main method |
| boolean data type has two or more values | false |
| The while loop executes a given statement or a block of statements for a definite number of times. | false |
| The statements associated with default keyword is executed if the value of the switch variable does not match any of the case constants. | true |
| What will be the output of the following program? int i, j, k, l = 0; k = l++; j = ++k; i = j++; System.out.println(i); | 2 |
| What is the operator in which the left operands value is moved left by the number of bits specified by the right operand. | << |
| What will be the output of the following program? int x = 42; double y = 42.25; System.out.println("x mod 10 = " + x % 10 ); System.out.println("y mod 10 = " + y % 10 ); | x mod 10 = 2 y mod 10 = 2.25 |
| The statements associated with this keyword is executed if the value of the switch variable does not match any of the case constants. | default |
| 4>>1 | 2 |
| What is the output of the following code fragment: int[] y = new int[5]; y[0] = 34; y[1] = 88; System.out.println( y[0] + " " + y[1] + " " + y[5] ); | The program is defective and will not compile. |
| What will be the output of the following program? class ArrayOutput { } | Throws ArrayIndexOutOfBoundsException |
| int count = 0; for ( ; count < 9; ++coConsider the following codes: int x=3; System.out.println(x++); What will be the EXACT output?unt ) System.out.print( count + " " ); System.out.println( ); | 0 1 2 3 4 5 6 7 8 |
| Consider the following codes: int x=3; System.out.println(x++); What will be the EXACT output? | 4 |
| What must the initialization be so that the following fragment prints out the integers -3 -2 -1 ? for ( _______; j < 0; j++ ) System.out.print( j + " " ); System.out.println( ); | int j = -4 |
| Consider the following codes: int x=4; System.out.println(--x); What will be the EXACT output? | 3 |
| What is the operator in which The left operands value is moved right by the number of bits specified by the right operand and shifted values are filled up with zeros. | >>> |
| Assigns values from right side operands to left side operand. | = |
| class CalculateSum { } | Throws ArrayIndexOutOfBoundsException |
| If any of the two operands are non-zero, then the condition becomes true. | || |
| What is the output of the following code fragment: int[] ar = {2, 4, 6, 8 }; System.out.println( ar[0] + " " + ar[1] ); | 2 4 |
| boolean lampX = false, result; boolean lampY = true; result = lampY &The case statement is used to conditionally perform statements based on an integer expression & lampX; System.out.println("Lamp switch-on " + result); | Lamp switch-on false Lamp switch-on false |
| The case statement is used to conditionally perform statements based on an integer expression | true |