src/main/java/sorting/SortingDemo.java
public List<String> lengthSortThenReverseAlphaUsingSorted() {
        return sampleStrings.stream()
                .filter(Objects::nonNull)
                .sorted(comparing(String::length)
                        .thenComparing(reverseOrder()))
                .collect(toList());
    }
// Sort by length then reverse alpha using sorted
Sort by length then reverse alpha using sorted
Sort by length then reverse alpha using sorted
public List<String> lengthSortThenReverseAlphaUsingSorted() {
        return sampleStrings.stream()
                .filter(Objects::nonNull)
                .sorted(comparing(String::length)
                        .thenComparing(reverseOrder()))
                .collect(toList());
    }
public List < String > lengthSortThenReverseAlphaUsingSorted ( ) { return sampleStrings . stream ( ) . filter ( Objects :: nonNull ) . sorted ( comparing ( String :: length ) . thenComparing ( reverseOrder ( ) ) ) . collect ( toList ( ) ) ; }
Sort by length then reverse alpha using sorted
Sort by length then reverse alpha using sorted