0

What's a valid function signature for funSig?

funSig(() -> System.out.println());
Stefan K.
  • 7,429
  • 6
  • 47
  • 61

1 Answers1

7

A Runnable would work,

It matches a void return and no params.

Runnable runnable = () -> System.out.println();

And obviously it doesn't need to be Runnable, any Functional Interface that matches the signature will do.

Sleiman Jneidi
  • 22,151
  • 12
  • 53
  • 74