The sum of 5 consecutive even integers is 50. What is the middle one?

Can you show the equation and how you solved it please?

x-4 + x-2 + x + x+2 + x+4 = 50

5 x = 50

x = 10