Interview Question | Comparable vs Comparator in Java
In this video we will see :
- Comparator and Comparable in Java
- Difference between Comparator and Comparable
- Example of Comparator and Comparable
- Create getters and setters
- toString() methpd
- Creating List and adding values in List
- Collection.sort method to sort the List
- When to use Comparable and when to use Comparator
- compareTo() method
- How to use comparable
- How to use Comparator
#java #interview
Editing Monitors :
https://amzn.to/2RfKWgL
https://amzn.to/2Q665JW
https://amzn.to/2OUP21a.
Check out our website: http://www.telusko.com
Follow Telusko on Twitter: https://twitter.com/navinreddy20
Follow on Facebook:
Telusko : https://www.facebook.com/teluskolearn...
Navin Reddy : https://www.facebook.com/navintelusko
Follow Navin Reddy on Instagram: https://www.instagram.com/navinreddy20
Subscribe to our other channel:
Navin Reddy : https://www.youtube.com/channel/UCxmk...
Telusko Hindi :
https://www.youtube.com/channel/UCitz...
Donation:
PayPal Id : navinreddy20
Patreon : navinreddy20
http://www.telusko.com/contactus
-
Category
No comments found