Is null a keyword? if not what is it?
Latest Answer: "null" is not a keyword, but a special literal of the null type. It can be cast to any reference type, but not to any primitive type such as int or boolean. The null literal doesn't necessarily have value zero. And it is impossible to cast to the null ...
What exactly is the difference between between throw and throws? If both are used for the same purpose then why are both needed instead of one?
Latest Answer: hi there, throw:the throw keyword is used to throw the exception manually,that is when you feel a particular line in your code, when executed is capable of having some exception ...
What will happen if same access specifier repeats more than once within a class?
Latest Answer: Can you please make the question clear? ...
When We should use Synchronization in Java and when we should not?
Latest Answer: There are two types of variables.1. local variables 2. static or instance variables.local valiables like method parameters are stored in stacks and instance are stored in Heap. You are not bothered to take care for any local things for synchronizations ...
suppose i have 2 members in my class can i serialize a single member? Is there any way to do that?
Latest Answer: how about move the other 24 member variable to a class?... ...
What is Use of declaring an array list object like List list = new ArrayList() rather than creating object like ArrayList arr = new ArrayList();
Latest Answer: List is an interface where as Arraylist is a class.Arraylist implements all the methods in List...So the arraylist's methods are invoked as the method body is present in Arralist ...
We usually extend Exception instead of Throwable. Why? In what situations we extend Throwable.Could anybody give the answer in detail. Thanks in advance.
Latest Answer: Extending the Exception class (a descendant of Throwable) instead of extending Throwable itself is a programming convention, not a requirement.Like most conventions, following the convention lends consistency to the end result. ...
Latest Answer: yes absolutely .if the receiving type is String, then both teh operands will concatenate and form 5.453.2 as an answer.but if teh recieving type is a primitive type, then that wud be a error. ...
Latest Answer: Yes we can declare interface in servlet through httpservlate ...
What is the output of the following program, When tested under JDK 5.0class ExceptionDemo{ public static void main(String[] args) { int a[] = new int[] {1,2,3,4,5}; try{ System.out.prinltln(a[6]);
Latest Answer: Here the child exception is caught before parent. In your program there are two compilation errors they are println is typed wrong and ArrayIndexOutOfBoundsException is also typed worng which result in compilation errors ...
View page [1] 2 3 4 5 6 7 8 9 10 Next >>

Go Top