I want to call a constructor for MySortedSet that takes in a Comparator c as a parameter. How can I modify this to do so?
public MySortedSet subSet(
You can’t use method references if you want to pass additional captured values as parameters. You will have to use a lambda expression instead:
MySortedSet<E> :: new
=>
() -> new MySortedSet<E>(c)