---
title: "#comparable-vs-comparator articles | Hashnode"
description: "Explore 5 articles tagged #comparable-vs-comparator on Hashnode. Tutorials, guides, and how-tos from the community."
url: "https://hashnode.com/tag/comparable-vs-comparator"
---

Tag

# #comparable-vs-comparator

5 posts · 0 followers

[Kunal Krishna](https://hashnode.com/@kunalkrishna85) · [Jan 2](https://hashnode.com/posts/comparison-in-java-comparator-vs-comparable/6957bdad673c0208590b2112)

### [Comparison in Java : Comparator vs Comparable](https://compator-vs-comparable.hashnode.dev/comparison-in-java-comparator-vs-comparable?utm_source=hashnode&utm_medium=feed)

The question is never whether to compare or not but how to compare?

16 min read · [compator-vs-comparable.hashnode.dev](https://compator-vs-comparable.hashnode.dev/comparison-in-java-comparator-vs-comparable?utm_source=hashnode&utm_medium=feed)

[chanbasha](https://hashnode.com/@javaeduacademy) · [Dec 31, 2025](https://hashnode.com/posts/comparable-part1/6954e4b40fffff6d90e82a86)

### [Comparable Part-1](https://javaeduacademy.hashnode.dev/comparable-part1?utm_source=hashnode&utm_medium=feed)

Comparable : When we work with objects in Java, sometimes we want to sort them. For example : Sort employees by salary Sort students by marks Java does not know how to compare custom objects automatically.This is where Comparable comes in. What i...

5 min read · [javaeduacademy.hashnode.dev](https://javaeduacademy.hashnode.dev/comparable-part1?utm_source=hashnode&utm_medium=feed)

[Francesco Tusa](https://hashnode.com/@ftusa) · [Dec 5, 2025](https://hashnode.com/posts/bringing-order-to-chaos-with-sorting/69341a7055747af338e29a8d)

### [Bringing Order to Chaos with Sorting](https://thinkobjectoriented.hashnode.dev/bringing-order-to-chaos-with-sorting?utm_source=hashnode&utm_medium=feed)

Use Java's Comparable and Comparator interfaces for efficient custom object sorting and flexible strategies in data handling

4 min read · [thinkobjectoriented.hashnode.dev](https://thinkobjectoriented.hashnode.dev/bringing-order-to-chaos-with-sorting?utm_source=hashnode&utm_medium=feed)

[Imran Ansari](https://hashnode.com/@ahtechschool) · [Jun 25, 2025](https://hashnode.com/posts/java-sorting-using-comparable-and-comparator-together/685c19e7b69fc2ee2122dc91)

### [Java Sorting: Using Comparable and Comparator Together](https://ahtechschool.hashnode.dev/java-sorting-using-comparable-and-comparator-together?utm_source=hashnode&utm_medium=feed)

Mastering Object Sorting with Real Examples

2 min read · [ahtechschool.hashnode.dev](https://ahtechschool.hashnode.dev/java-sorting-using-comparable-and-comparator-together?utm_source=hashnode&utm_medium=feed)

[Chetan Datta](https://hashnode.com/@chetan77) · [Jun 9, 2024](https://hashnode.com/posts/19-java-priority-queue-compartor-vs-comparble/6665417a6391eb3acf886282)

### [19 Java - Priority Queue, Compartor vs Comparble](https://chetan77.hashnode.dev/19-java-priority-queue-compartor-vs-comparble?utm_source=hashnode&utm_medium=feed)

Priority Queue Queue is an interface, child of Collection interface. Generally Queue follows FIFO approach, but there are exceptions like PriorityQueue Supports all the methods available in Collection + some other methods mentioned below Method...

7 min read · [chetan77.hashnode.dev](https://chetan77.hashnode.dev/19-java-priority-queue-compartor-vs-comparble?utm_source=hashnode&utm_medium=feed)
