FERMAT 2017 Problem 6

Emilia writes down the numbers 5,x and 9. Valentin calculates the mean (average) of each pair of these numbers and obtains 7,10 and 12. The value of x is

Answer Choices
A. 5
B. 15
C. 3
D. 25
E. 1