What will be the output of the following Java program?
Predict the output of the following Java code.
XML based data transfer and JSON based data transfer are the alternatives to Serialization in java
Which of these methods of the Double wrapper class can be used to check whether a given value is infinite or not?
Predict the output of the following Java code.
class Abekus {
public static void main(String args[])
{
String s1 = "Welcome to Abekus.";
boolean b1;
b1 = s1.startsWith("hello");
System.out.println(b1);
}
}
What will be the output of the following program?
class output
{
public static void main(String args[])
{ String s = "Hello World";
int i = s.indexOf('o');
int j = s.lastIndexOf('o');
System.out.print(i + " " + j);
}
}
What will be the output of the following code?
class A
{
int a;
int b;
A()
{
a = 1;
b = 2;
}
}
class Output
{
public static void main(String args[])
{
A obj = new A();
System.out.print(obj.toString());
}
}
public class outputs
{
public static void main(String args[])
{
int arr [] = new int[20];
for (int i = 0; i < 20; ++i)
{
arr[i] = i;
System.out.print(arr[i] + " ");
i++;
}
}
}
// It is a class Abekus.
package com.pk3;
public class Abekus{
public void m1()
{
System.out.println("Protected method of Abekus has been called.");
}
}
// This is def class.
package com.pkg2;
import com.pk3.Abekus;
public class def extends Abekus {
public static void main(String args[]) {
Abekus A = new Abekus();
A.m1();
System.out.println("This is Abekus.com");
}
}
What will be the correct output?