Let the number to be added be x.
the numbers 5,11,12,21 will be 5+x,11+x,12+x,21+x
(5+x)/(11++x)=(12+x)/(21+x)
Cross multiplying
(5+x)(21+x)=(12+x)(11+x)
(a+b)(c+d)=ab+ad+bc+bd
105+26x+(x^2)=132+23x+(x^2)
26x-23x=132-105
3x=27
x=9
The answer is 9.