How many states does a thread go through during its lifetime?
In class level lock, lock is acquired on class as well as on class instance
Which of the following methods is used only within a session?
Which of these events is generated by a scroll bar?
public int end(int group) return offset from the first character of the subsequent group
Collections.retainAll(java.util.Collection) is used to
Which of these classes is used to access the actual bits or content information of a URL?
Statement 1- Array.sort()
Statement 2- Collection.sort()
Statement 3-Arrays.sort()
What will be the output of the following Java program?
import java.net.*;
class Networking {
public static void main(String[] args) throws UnknownHostException {
InetAddress obj1 = InetAddress.getByName("cisco.com");
System.out.print(obj1.getHostName());
}
}
What is the output of the following code?
//Predict the output
import java.util.Scanner;
public class MyClass
{
public static void main(String args[])
{
StringBuffer str = new StringBuffer("NorthIndia");
str.reverse();
System.out.println(" " + str);
}
}