Which lambda can replace the MyConverter
class to return the same value?
Choose all that apply
interface Converter { String convert(double d); } class MyConverter implements Converter { public String convert(double d) { return "Poof"; } }
A, F.
Option B is incorrect because it does not use the return keyword.
Options C, D, and E are incorrect because the variable e is already in use from the lambda and cannot be redefined.
Additionally, option C is missing the return keyword and option E is missing the semicolon.