Studies of charm quark diffusion inside jets using PbPb and pp collisions at $\sqrts_\mathrmNN =$ 5.02 TeVстатья