Answer
p = -2
Work Step by Step
The given relation is $a=2xt^p$....eq(1)
We know that the dimension of distance $x=[L]$
The dimension of acceleration is $[LT^{-2}]$
and the dimension of time $t=[T]$
and the number $2$ is constant and dimensionless.
Now eq(1) becomes
$[LT^{-2}]=[L][T]^p$
Comparing both sides, we obtain:
$p=-2$