Shortest possible way to write this function

Printable View