NEW
Font size
WorksheetsJava Programming
Total questions: 15
Worksheet time: 5mins
Java programs are
Faster than others
Platform independent
Not reusable
Not sacable
Java has its origin in
COBOL
PERRL
Oak programming language
C language
Which one of the following is true for java
Java is object oriented and interpreted
Java is efficient and faster than C
Java is the choice of everyone
Java is not robust
The command javac is used to
Execute a Java program
Compile a Java program
Debug a Java program
Interpret a Java program
……………. are not machine instructions and therefore, Java interpreter generates machine code that can be directly executed by the machine that is running the Java program.
Compiled instruction
Compiled code
Byte code
Java mid code
Which of the following is not the Java primitive type
Byte
Float
Character
Long double
Which of the following is true about Java.
Java does not support overloading.
Java has replaced the destructor function of C++
There are no header files in Java.
All of the above
All Java classes are derived from
java.lang.Class
java.util.Name
java.lang.Object
java.awt.Window
Which of the following is not mandatory in a variable declaration?
a semicolon
an identifier
an assignment
a data type
What would happen if “String[]args” is not included as an argument in the main method?
No error
Compilation error
The program won’t run
Program exit
In Java variables, if first increment of the variable takes place and then the assignment occurs. This operation is also called…………………………
pre-increment
post-increment
incrementation
pre incrementation
The compiled Java program can run on any ………………… platform having Java Virtual Machine (JVM) installed on it.
Program
Hardware
Java
Non java
The information written in java after // is ignored by the
Programmer
Interpreter
Compiler
All of the above
When the operators are having the same priority, they are evaluated from …………….. …………. in the order they appear in the expression.
right to left
left to right
Any of the order
Depends on the compilor
State true or false for Java Program.
i) All class variables are instance variables
ii)An abstract class has implementations of all methods defined inside it.
i-false, ii-false
i-false, ii-true
i-true, ii-false
i-true, ii-true
