About Question enthuware.ocpjp.v11.2.3318 :
Posted: Sat Feb 04, 2023 3:55 am
The last option is a bit confusing
Runnable r = ()-> 1+2; would not compile but someMethod() (which returns an int) compiles? How could you explain this?
Runnable r = ()-> 1+2; would not compile but someMethod() (which returns an int) compiles? How could you explain this?