A functional interface is an interface with exactly abstract method. Java marks many of these with the @FunctionalInterface annotation, but the annotation is optional. What matters is the single abstract method.
Comparator is a functional interface because it has one abstract method: compare(). So is Runnable with its run() method.
Why does this matter? Functional interfaces are the foundation for lambda expressions, which you'll learn in a later section. A lambda is a short way to implement a functional interface without writing a full class.
Comparator<Student> byGpa = (a, b) -> Double.compare(a.gpa, b.gpa);
That single line replaces the entire anonymous class you wrote earlier. For now, just remember: abstract method means the interface qualifies for lambda syntax.