which one is more efficient
int x;
1. if(x==null)
2.if(null==x)
state which one either 1 or 2?
Answer Posted / sudhanshu
1. if (x==null)
is the correct answer.
| Is This Answer Correct ? | 21 Yes | 8 No |
Post New Answer View All Answers
Explain wait() method of object class ?
How does linkedhashmap work in java?
Why are the destructors for base class and derived class called in reverse order when the program exits
Differentiate jar and war files?
What is skeleton and stub?
What is the memory leak in java?
How do you execute a thread in java?
FOR EXAMPLE WE R HAVING TWO LIST ELEMENTS ..BOTH LISTS CONTAINS ID,NAME,PLACE ..I NEED TO COMPARE BOTH IDS IN TWO LISTS,IF ID'S R SAME MEANS WE HAVE ADD THE DETAILS(LIKE NAME,PLACE) TO MAP...HOW IS POSSIBLE ?CAN ANY ONE SUGGEST?
What is meant by local variable and instance variable?
What is class and object in java?
Difference between operator overloading and function overloading
How do generics work?
What are the 6 functions?
What is set in java?
What is a private class in java?