Online Test

:

 

How can we create an unsigned int variable in Java?


Which of these methods can be used to obtain the reference to the container that generated a ContainerEvent?


If an expression contains double, int, float, long, then whole expression will promoted into which of these data types?


Which two of the following methods are defined in class Thread?

  1. start()
  2. wait()
  3. notify()
  4. run()
  5. terminate()

What would be the signature of a method myfunc() that :

1. Has a double array as a formal parameter 

2. Returns an array of integers.


An expression involving byte, int, and literal numbers is promoted to which of these?


What is the range of data type short in Java?


What will this code print?
int arr[] = new int [5];
System.out.print(arr);


Which of these packages contains the exception Stackoverflow in Java?


You need to store elements in a collection that guarantees that no duplicates are stored and all elements can be accessed in natural order. Which interface provides that capability?


What will be the output of the program?

class Test 
{
    public static void main(String [] args) 
    {
        int x=20;
        String sup = (x < 15) ? "small" : (x < 22)? "tiny" : "huge";
        System.out.println(sup);
    }
}

Which three are valid method signatures in an interface?

  1. private int getArea();
  2. public float getVol(float x);
  3. public void main(String [] args);
  4. public static void main(String [] args);
  5. boolean setFlag(Boolean [] test);

You want subclasses in any package to have access to members of a superclass. Which is the most restrictive access that accomplishes this objective?


What will be the output of the program?

public class Foo 
{  
    public static void main(String[] args) 
    {
        try 
        { 
            return; 
        } 
        finally 
        {
            System.out.println( "Finally" ); 
        } 
    } 
}

A _________ is a basic unit of storage in Java.

 

About Us

TechEpi.com is an online learning website.We cover the latest tech news,online tutorials,blog,online test for Aptitude,C,Java,PHP to improve your knowledge.

Newsletter


Follow TechEpi on