Skip to content

Commit b4c480c

Browse files
Update README.md
1 parent 52da93e commit b4c480c

File tree

1 file changed

+16
-3
lines changed

1 file changed

+16
-3
lines changed

README.md

Lines changed: 16 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3936,8 +3936,11 @@ new ConcurrentSkipListMap<>(comparator)
39363936

39373937
Constructs a new, empty map, sorted according to the specified comparator.
39383938

3939-
:Already Discussed Earlier:
3939+
Here Class implements Comparator interface for comparison.
39403940

3941+
Generally negative comparison : ReverseOrder
3942+
3943+
Generally positive comparison : AscendingOrder/NaturalOrder
39413944

39423945
```
39433946
@@ -3947,7 +3950,11 @@ Constructs a new, empty map, sorted according to the specified comparator.
39473950

39483951
Constructs a new, empty map, sorted according to the specified comparator.
39493952

3950-
:Already Discussed Earlier:
3953+
Here Comparator object is passed inside Constructor.
3954+
3955+
Generally negative comparison : ReverseOrder
3956+
3957+
Generally positive comparison : AscendingOrder/NaturalOrder
39513958

39523959

39533960
```
@@ -3958,8 +3965,14 @@ Constructs a new, empty map, sorted according to the specified comparator.
39583965

39593966
Constructs a new, empty map, sorted according to the specified comparator.
39603967

3961-
:Already Discussed Earlier:
3968+
Here Direct Comparator Class is called inside Constructor.
3969+
3970+
Comparator.reverseOrder(): Gives Reverse Order of Values
3971+
Comparator.naturalOrder(): Gives Natural Order of Values
3972+
3973+
Any negative comparison : ReverseOrder
39623974

3975+
Any positive comparison : AscendingOrder/NaturalOrder
39633976

39643977
```
39653978

0 commit comments

Comments
 (0)