How many methods does the Serializable interface have?
The third type of comment for automatic generation of documentation is used by
Which access modifier is used to access a member of a class before an object of that class is created?
class test{
public static void main (String[] args) {
int x=1,y=16;
x=x>>2;
y=y>>x;
System.out.println(~x<<2);
}
}
public class check{
public static void main(String args[]){
StringBuilder sb= new StringBuilder("java is simple");
System.out.println(sb.length());
}
}
class Main {
public static void main(String args[]){
final int a;
a = 20;
a = 30;
System.out.println(a);
}
}
What is the output of the following program?
class output
{
public static void main(String args[])
{
String s1 = "Hello World";
String s2 = s1.substring(0 , 3);
System.out.println(s2);
}
}
public class output
{
public static void main(String args[])
{
double a = 4.5;
double b = 5.5;
double c = Math.max( a, b );
System.out.print(c);
}
}
What will be the output of the following Java program?
import java.lang.System;
class Output
{
public static void main(String args[])
{
byte a[] = { 65, 66, 67, 68, 69, 70 };
byte b[] = { 71, 72, 73, 74, 75, 76 };
System.arraycopy(a, 0, b, 3, a.length - 3);
System.out.print(new String(a) + " " + new String(b));
}
What will be the output of the following Java program?
class newthread implements Runnable
{
Thread t;
newthread()
{
t = new Thread(this,"My Thread");
t.start();
}
}
class multithreaded_programing
{
public static void main(String args[])
{
new newthread();
}
}