I know this is a piecewise expression, but I didn't know you can use max( and min( in this way. Could someone explain how it works, syntax for all cases, etc.
Work from the end of the expression:
Assuming Ans is the keypress and A is the position of the paddle, it first moves it.
This makes sure that A is not out of bounds. If A is less than or equal to the maximum boundary, the calculator is left with A. If A is outside the boundaries, it takes the maximum boundary for A.
This does the same thing, comparing A to the lower boundary, and taking A if A is within the boundaries, and the minimum boundary if A is lower than it.