In order to factor, we must pull out factors common to each term. In this case, each term has factors of 2 and y:
4ay = 
2 * 2 * a * 
y
2y = 
2 *
 y
So, we'll pull out the 2y:

To check, distribute the 2y back through the terms in parentheses to ensure you end up with the original expression 4ay - 2y.