శ్రీనివాస్ గారు, equals, hashCode మధ్య తేడాని బాగా వివరించారు. థ్యాంక్యూ ! Credit is where credit due.
@java9s8 жыл бұрын
+Common Yunus thank you. Happy to see your comment
@Adam-gp3ij5 жыл бұрын
Sir, this is insane ! thank you so much ! we pay a lot of Money without a 1% of these explanations in the university ! thank you again
@niebboycyrax6 жыл бұрын
Really helpful, thank you sir.
@AihQuresh8 жыл бұрын
Great explanation!
@kumarshivam7605 жыл бұрын
Very informative video. Please make a video on hashcode implementation and ovveriding also.
@text25648 жыл бұрын
Very informative. Thanks
@poornas95206 жыл бұрын
great video but why do you hit your keyboard so hard?
@sowmithgantla86747 жыл бұрын
wonderful explanation.
@naveenp48907 жыл бұрын
Simple and Lucid explanation. Respects!
@parthdalvi58556 жыл бұрын
Nice Explanation !! :-) Thanks !! :-)
@DeepakKumar-zk3dc2 жыл бұрын
As I know equals() method is used for content comparison while == is used to compare object address. That's why s.equals(s2) will generate true rather than false because content is same
@DR-pi9vk5 жыл бұрын
it will return true when you compare these objects: Student s and Student s2 with equals, because they have the same object argument
@jyotipalapure46236 жыл бұрын
s.equals(s2) method will return true, not false.
@MuthuKumar-qi2um8 жыл бұрын
good explanation
@dips28057 жыл бұрын
excellent explanation... please make a video on how to authenticate rest web services using OAuth and OAuth 2.
@2010lakshitha4 жыл бұрын
thank you!!!
@dhiru78537 жыл бұрын
i have equals and hashcode methods when am tryin to give same values to 2 different objects and trying to do this obj1==obj2 its giving false but its giving true for (obj1.equals(obj2)) what should i do to get true for obj1==obj2????
@sunilmaurya90866 жыл бұрын
dhi ru == compares memory location just see if hashcode is correct
@MrJonnis138 жыл бұрын
Is it true that hashcode returns the memory location of the object, converted to an integer ? OR it returns something irrelevant of the memory location ?
@java9s8 жыл бұрын
+Yiannis Ioannidis true.. Check the object class documentation here docs.oracle.com/javase/7/docs/api/java/lang/Object.html
@MrJonnis138 жыл бұрын
+java9s Thanks a lot for this, and for your effort making these videos in general !
@PawanKumar-lf2cb8 жыл бұрын
class Equls { public static void main(String[] args) { String s1 = new String("hell55o"); String s2 = new String("hell55o"); System.out.println(s1.equals(s2)); } } i am confused :\ ? becons ans is true you are telling false :(
@pjain71908 жыл бұрын
Because String is predefined class having implemented Equals and HashCode function it.
@DilipSirClass8 жыл бұрын
Yiannis Ioannidis in java there is no way to find out address.
@krayziesensei6 жыл бұрын
Excellent explanation. Thank you, sir.
@manideepreddygeetla30784 жыл бұрын
What you said at 3.07 sec is false ,it returns true
@djanupamdas6 жыл бұрын
Ultimate explanation..perfect coding pace..can you please create a playlist for Spring Core, Spring Mvc, Spring Boot..
@prathameshrane20478 жыл бұрын
Got It Clearly Now....
@jaydipbarvaliya4 жыл бұрын
please come up with some diagram before handson! so learners easily grasp whatever you gonna do
@DeepakKumar-zk3dc2 жыл бұрын
class EqualsMethod { public static void main(String[] args) { String s = new String("Deepak"); String s2 = new String("Deepak"); System.out.println("Equals method "+s.equals(s2)); // true System.out.println(s == s2); // false } }
@sendacool888 жыл бұрын
thank you for video . some time i saw number next hashcode like this one 97 * hash + Objects.hashCode(this.profileId); +
@B-Billy7 жыл бұрын
Yes, that number is should be a PRIME NUMBER. Its used to calculate hash code for customized object. The number is useful because the aim of calculating of hash code is to get unique hash code for each and every object and here this PRIME NUMBER helps a lot.
@DoomInSor7 жыл бұрын
thank yoooooooo
@riteshsingh88135 жыл бұрын
Could have been better if you would have explained the hierarchy how they are called along with purpose. You kept on repeating this is helpful rather than you should explain how it works.
@bhanuchandar44195 жыл бұрын
Sir u have to explain for every line why what and when u didn't follow please next time onwards try follow clear ur English nice but explanation need to clear
@kamalraj-so5xm6 жыл бұрын
not clear explanation. not at all satisfied
@vijaychaudhari14045 жыл бұрын
not satisfy wrong explanation of equal method
@subhasisroy44624 жыл бұрын
Not at all clear with this video. Very theoratical