Core Java
--------------------------------------------------------------------------------
1. Difference between ArrayList, Vector
2. Hierarchy of Collection interface
3. How multiple inheritance can be achieved?
4. Significance of inheritance
5. Difference between static, final, abstract
6. What is the use of inner classes?
7. What is the Properties class
8. How many ways thread can be created?
9. When to implement Runnable interface and when to go for extends Thread
10. How to get the persistence using threads
11. If 3 functions are written using synchronized modifier, is it possible to assign each function to one thread.
12. How to get the list of files in a directory?
13. Which is better stream character or binary?
14. What is the significance of monitor?
15. Can we lock the thread?
16. How can a deadlock be prevented?
17. Explain any one condition which there is a possibility of occurring deadlock?
18. Difference between list, map, set interfaces.
19. Which class has all static methods?
20. Explain object oriented concepts?
21. What is difference between compile time polymorphism and runtime polymorphism?
22. What is the root class of all classes? what are the methods in that class?
Ans: Object class. The methods in this class are, clone() , equals(), finalize()
23. Is it okay?
String s = new Object();
Object o = new String();
Ans: b is correct, whereas while using a, type casting is required at the right hand side.
24. What are the Collections framework classes you used in your project.
25. How the HashMap is different from the Hashtable?
26. What is the situation to write the private constructor?
27. What is the advantage in using the Singleton Object Pattern to be used?
28. Why should we go for interfaces instead of using the abstract classes?
29. What is inner classes used for?
30. How to get an array from an ArrayList object ?
31. Framework and component difference.
32. What is the difference between String and StringBuffer...and what is that property called for String objects?
33. What will happen if u get an error in run() method of thread and if there is no try catch block for that?
34. Write sample code using wait() and notify() methods?
35. If a thread has obtained an lock on an object. Can other threads invoke non synchronized methods on the same object?
36. Explain the Exception hierarchy?
37. What is the diff b/w checked exceptions and unchecked exception and errors?
38. How to write our own exceptions? And can we write them without using super() in that?
39. What is encapsulation? Why do u need that?
40. What is event delegation in Swings?
41. Do you know about invokelater() in Swings...what is it for ?
42. What is a port?
43. Difference b/w client socket and server socket?
44. Is reading input from sockets a blocking call?
45. Difference b/w Readers and Streams in I/O?
46. How to open a file in read write mode..?
47. There is Date class in java.util..is there any other package which has the Date class?
48. If we import java.util.Date and java.sql.Date and use Date d= new Date()..what happens?
49. What is the difference b/w vector and arraylist?
50. What is the alternate for HashTable...?
51. What is the difference b/w iterator and enumeration?
52. How can u sort a collection?
53. What is the difference b/w function and stored procedures?
54. Different Layouts in Swings?
55. Explain the use of Timer class?
56. Significance of BufferedReaders over others?
57. Difference b/w TCP and UDP connection?
58. Can we dram class diagrams from use case diagrams?
59. Difference b/w sequence diagrams and collaboration diagrams?
60. What are the different classes from UTIL package?
61. How can we get inter thread communication?
62. Different methods of threads that makes the running thread to stop running and go to some other state? And the difference b/w those methods?
63. How to get system properties like OS name etc?
64. How do u launch an executable using java code?
65. What is garbage collection...explain functionally and physically?
66. Which is the best out of vector and hashtable performance wise. which is thread safe..?
67. Explain Exception heirarchy?
68. How do u specify that a class throws exceptions?
69. Why do we need finally?
70. Do we need to catch RunTime exceptions explicitly?
71. Difference between interface and Abstract class?
72. How many access specifiers are there...explain each of them?
73. Suppose a super class is having a method with access specifier public. Can a subclass overriding that method can have a access specifier as private?
74. How do u extend the memory size of the JVM.
75. How to remove a single class from the memory which is occupying more space.
76. What is a singleton class.
77. If we have a return in Catch block, does it excute finally.
78. If a parent class catches the exception, does the chld class which extends it also catches the exception.
79. How do u implement dynamic polymorphism in Java.
80. What r various uses of static.
81. What is Event delegation in java.
82. How to stop a variable from being stored in memory(I think 'transient')
83. how does gc work what type of thread is it
84. what is a deamon thread
85. why is main declared as static
86. what is a classloader
87. what is a bytecode verifier
88. What is encapsulation? What is 100% encapsulation?
89. What are the advantages of encapsulation?
90. What is overloading? Why do u use this?
91. What is method signature? Does it comprise the return type?
100. What is a stored procedure? What does it return?
101. How do u use out parameters? How do use this in java?
102. Differences between AWT and Swing.
103. Usecases , class diagrams,sequence diagrams -- draw the diagrams for a task
104. Design patterns - singleton,service locator
105. Event delegation model
106. Applet - lifecylce
107. Usage of this and super keywords.
108. default keyword scope.
109. anonymous classes - types of variables it can access.
110. What is the difference between Pointers and References ?
111. can we see the byte codes ?
112. what difference b/w Bytecodes and byte ?
113. The differene b/w Cursor and Trigger ?
114. The differene b/w Procedure and Function ?