If p varies directly as the cube of x and p=27,x=3 find p when x=2

If $p$ varies directly as the cube of $x$, this can be represented by the equation $p = kx^3$, where $k$ is the constant of variation. Since we are given that $p = 27$ when $x = 3$, we can substitute these values into the equation and solve for $k$:

$27 = k(3)^3$
$27 = 27k$
$k = 1$

Now that we have the value of $k$, we can substitute $x = 2$ back into the equation to find $p$:

$p = (1)(2)^3$
$p = 1(8)$
$p = 8$

Therefore, when $x = 2$, $p = 8$.