go-to is not a valid jump statement
Which of the following keyword is used to make a class?
Which of the following operators can operate on a boolean expression?
The correct way of inheriting class A by class B
Which of the following is invalid?
check the following statements
Statement 1 - \t
Statement 2 - \r
Statement 3 - \a
Statement 4 - \s
class test {
public static void main (String[] args) {
String s1=new String("Hello");
String s2=new String("Hello");
System.out.println((s1==s2)+" "+(s1.equals(s2)));
}
}
class test {
public static void main (String[] args) {
int x;
x=5;
{
int y=6;
System.out.println(++x+" "+y++);
}
System.out.println(x);
}
}
public class j
{
public static void main(String args[])
{
String s1 = new String("Java is plaform independent");
boolean result;
result= s1.startsWith("java");
System.out.println(result);
}
}
Predict the output of the following Java code:
class Abekus {
public static void main(String args[])
{
String str = "JavaProgramming";
String str1 = "Java";
System.out.println(str.compareTo(str1));
System.out.println(str1.compareTo(str));
}
}