Skip to main content
Journey Uncommon Logo
JourneyUncommon
mediumJavafunctional interfacesSingle-choice MCQ

Why does overloading prevent this lambda assignment from compiling cleanly without a cast?

interface A { String run(); } interface B { Integer run(); } void go(A a) {} void go(B b) {} // caller: go(() -> "text");