V^2=u^2+2as
27^2=u^2+2x10x15
27^2=u^2+300
solve for u to get speed gun fires pellet.
then use v^2=u^2-2as
v=0 at height ... u found above ... a=10 ...s = what you want