Fundamentals of Object-Oriented Programming Questions and Answers

Learn tutorial from this Chapter Fundamentals of Object-Oriented Programming


 What is computer ?


 List five major hardware components of a computer.


 What does the acronym "CPU" stand for?


 What unit is used to measure CPU speed?


 What is a bit? What is a byte?


 What is memory for? What does RAM stand for? Why is memory called RAM?


 What unit is used to measure memory size?


 What unit is used to measure disk size?


 What is the primary difference between memory and a storage device?


 What language does the CPU understand?


 What is a Java applet?


 What programming language does Android use?


 What is the Java language specification?


 What is the statement to display the message "Hello world" in a message dialog box?


 Why does the System class not need to be imported?


 Are there any performance differences between the following two import statements?
import javax.swing.JOptionPane;
import javax.swing.*;


 Reformat the following program according to the programming style and documenta- tion guidelines. Use the end-of-line brace style.


 Variables used in a switch statement can be used with which datatypes?


 When parseInt() method can be used?


 Why is String class considered immutable?


 Why is StringBuffer called mutable?


 What is the difference between StringBuffer and StringBuilder class?


 Which package is used for pattern matching with regular expressions?


 java.util.regex consists of which classes?


 What is finalize() method?


 What is an Exception?


 What do you mean by Checked Exceptions?


 Explain Runtime Exceptions?


 Which are the two subclasses under Exception class?


 When throws keyword is used?


 When throw keyword is used?


 How finally used under Exception Handling?


 What things should be kept in mind while creating your own exceptions in Java?


 Define Inheritance?


 When super keyword is used?


 What is Polymorphism?


 What is Abstraction?


 What is Abstract class?


 When Abstract methods are used?


 What is Encapsulation?


 What is the primary benefit of Encapsulation?


 Explain the usage of this() with constructors?


 Explain the following line used under Java Program ? public static void main (String args[ ])


 What is the difference between a Window and a Frame?


 Which package has light weight components?


 What is the difference between the paint() and repaint() methods?


 What is the purpose of File class?


 What is the difference between the Reader/Writer class hierarchy and the InputStream/OutputStream class hierarchy?


 Which class should you use to obtain design information about an object?


 What is the difference between static and non-static variables?


 What is Serialization and deserialization?


 What are use cases?


 Explain the use of sublass in a Java program?


 How to add menushortcut to menu item?


 What is synchronization?


 What is the Collections API?


 What is the relationship between clipping and repainting under AWT?


 What are ClassLoaders?


 What will happen if static modifier is removed from the signature of the main method?


 Can a top level class be private or protected?


 Is it necessary that each try block must be followed by a catch block?


 When a thread is created and started, what is its initial state?


 What is the Locale class?


 What are synchronized methods and synchronized statements?


 What is runtime polymorphism or dynamic method dispatch?


 What is Dynamic Binding(late binding)?


 What are the advantages of ArrayList over arrays?


 Why deletion in LinkedList is fast than ArrayList?


 How do you decide when to use ArrayList and LinkedList?


 What is a Values Collection View ?


 What is dot operator?


 Where and how can you use a private constructor?


 What is type casting?


 What is the difference between the >> and >>> operators?


 Which method of the Component class is used to set the position and size of a component?


 Define canvas?


 Define Network Programming?


 What is a Socket?


 Advantages of Java Sockets?


 Disadvantages of Java Sockets?


 Which class is used by server applications to obtain a port and listen for client requests?


 Which class represents the socket that both the client and server use to communicate with each other?


 Why Generics are used in Java?


 What environment variables do I need to set on my machine in order to be able to run Java programs?


 If System.exit (0); is written at the end of the try block, will the finally block still execute?

Share Me:

Visit Our Fb Page: