JAVA TEST

Progress

1.

HTML web pages can be read and rendered by _________.

2.

Java object oriented programming concepts is/are

3.

Super keyword in java is used to

4.

Which statement provides an easy way to dispatch execution to different parts of your code based on the value of an expression?

5.

What is the string contained in s after following lines of code?
 StringBuffer s new StringBuffer("Hello);
 s.deleteCharAt(0);

6.

On which platforms Java runs?

7.

What is the value stored in x in following lines of code?
int x, y, z;
 x = 0;
 y = 1;
 x = y = z = 8;

8.

Which is a valid keyword in java?

9.

Encapsulation concept in java is

10.

Which of the following component of HTTP request contains metadata for the HTTP Request message as key-value pairs?

11.

Which models do the JDBC API support for the database access?

12.

HTML uses

13.

Each resource in REST architecture is identified by its URI.

14.

Which of the following operator has more precedence?

15.

True statements about object of Insurance class is/are
class Insurance{
int policyNumber;
}

public class Bank {
public static void main(String[] args) {
Insurance policy = new Insurance();
}
}

16.

Which of these method of class String is used to check weather a given object starts with a particular string literal?

17.

RESTful web services must be stateful

18.

Find whether these two rules are correct or not defined by the constructor
1. Constructor name must be same as its class name.
2. Constructor must have no explicit return type.

19.

Which of these operators can be used to concatenate two or more String objects?

20.

When you wish to delete an existing “Foo” via a RESTful API, which is most appropriate

21.

Multiple inheritance means,

22.

What is the valid data type for variable "a" to print "Hello World"?
switch(a)
{
   System.out.println("Hello World");
}

23.

Which of these is a super class of all errors and exceptions in the Java language?

24.

Which annotation is used to represent command line input and assigned to correct data type?

25.

Which of these data types is used to store command line arguments?

26.

The insistence that RESTful APIs have URLs that identify resources in a consistent and predictable manner is known as:

27.

What must be enabled in order for a RESTful web service to receive invocations from different domains, subdomains or ports?

28.

What is the output for the following code, when you passed letsfindcourse at run time?
class CommandLineExample{  
public static void main(String args[]){  
System.out.println(""Your first argument is: ""+args[0]);  
}  

29.

Can we perform file handling in Java by Java I/O API?

30.

Which of the following is not true?

31.

What will be the output of the following Java program?
class abc
{
    public static void main(String args[])
    {
        if(args.length>0)
        System.out.println(args.length);
    }
}

32.

Which one of the following is not a Java feature?

33.

Which of those assortment categories has the flexibility to grow dynamically?

34.

____________method can be given parameters via using command line arguments.

35.

The default value of a static integer variable of a class in Java is,

36.

What is the name of the thread in output in the following Java program?
class multithreaded_programing
    {
        public static void main(String args[])
        {
            Thread t = Thread.currentThread();
            System.out.println(t.isAlive());        
        }
    }

37.

Which cannot directly cause a thread to stop executing?

38.

Which of these method of Thread class is used to find out the priority given to a thread?

39.

What will be the output of the following code snippet?

int a=15;

int b=25;

if ((a < b ) || ( a = 5)>15)

system.out.println(a);

else

system.out.println(b);

40.

What will be the output of the following code –
import java.util.Iterator;
import java.util.Map;
import java.util.concurrent.ConcurrentSkipListMap;

public class ConcurrentSkipMapTest {

public static void main (String args[])
{
Map<Integer,String> concurrentSkipListMap= new ConcurrentSkipListMap<Integer,String>();
concurrentSkipListMap.put(11,”audi”);
concurrentSkipListMap.put(44,”null”);

Iterator<Integer> keyIterator = concurrentSkipListMap.keySet().iterator();
while (keyIterator.hasNext())
{
System.out.print(keyIterator.next());

}
}

}

Assessment complete! Thank you for you time.
We are redirecting you to the result page, Please click on 'SUBMIT'