we are given that
P is a centroid
we know that
centroid always divides median into 2:1
so,
[tex] JP=\frac{2}{3} JM [/tex]
now, we can solve for JM
[tex] JM=\frac{3}{2} JP [/tex]
we are given
JP=27
so, we can plug it
[tex] JM=\frac{3}{2} *27 [/tex]
we get
[tex] JM=\frac{81}{2} [/tex]............Answer