Did you ever wonder why the Java programming language has two ways to compare if two variables or objects are equal? There is the equals method as well as the == (double equals) operator. Do you want to learn what the difference between them? There are some important pitfalls to keep in mind!
Specifically if you are new to programming in Java (e.g., come from a Minecraft background) or come from another language such as Python or JavaScript, this is one of the most important lessons to keep in mind.
This #Shorts guide only scratches the surface of the reasons behind what I am explaining, if you want to learn more in a proper tutorial, check out this other video on my channel that goes into more detail on the subject: • Java – .equals() vs. == (What is the diff...
If you have any suggestions for content or feedback please leave them in the comments.
In case you enjoyed this video, make sure to leave like, subscribe and share it with anyone you could consider interested!