What is Exception handling in Java How do you handle run time errors please explain with an example
2 6499public class AboutStrings{ public static void main(String args[]){ String s1="hello"; String s2="hel"; String s3="lo"; String s4=s2+s3; //to know the hash codes of s1,s4. System.out.println(s1.hashCode()); System.out.println(s4.hashCode()); // these two s1 and s4 are having same hashcodes. if(s1==s4){ System.out.println("s1 and s4 are same."); }else System.out.println("s1 and s4 are not same."); } } Somebody told me that, == operator compares references of the objects. In the above example even though s1 and s4 are refering to same object(having same hash codes), it is printing s1 and s4 are not same. Can anybody explain in detail why it is behaving like this? Thanks in Advance RavuriVinod
4 6307Post New TCS Core Java Interview Questions
Explain about services module?
Please explain what is a job scheduling?
How you can find the absolute value of the number in qtp?
Why cursor variables are easier to use than cursors?
What is the difference between hudson and jenkins?
What is query syntax?
What is the use of empty tags <> >?
What do you know about Development Officer job?
Explain the use of where clause in ms access sql?
How do you set up background jobs in sap? What are the steps? What are the events driven batch jobs?
Do you know how to debug the tests in selenium ide?
What are the assets and liabilities of a bank?
what are candidate key, alternate key and composite key? : Sql server database administration
I am 36 years old with graduation. Is it possible to get job in international bpo without any experience? Previously i was into my father business and due to some reasons business got shut down.
How to create object without using the keyword “new” in java?