Let the larger number be 'x' and smaller number be 'y'.
Since, the sum of two numbers is 21.
So,
(equation 1)
Since, the larger number is six less than twice the smaller number.
So,
(equation 2)
Substituting the value of 'y' from equation 2 in equation 1.
So,



So, y=9.
Since, x+y=21
x = 21-y
x = 21-9
x = 12.
So, the larger number is 12 and smaller number is 9.