Answer
$x=143202.5$
If you decide to round up:
$x=143203~units$
Work Step by Step
$p=42-\sqrt {0.001x+2}$
If $p=29.95$:
$29.95=42-\sqrt {0.001x+2}$
$\sqrt {0.001x+2}=42-29.95$
$\sqrt {0.001x+2}=12.05~~$ (square both sides):
$(\sqrt {0.001x+2})^2=12.05^2~~$
$0.001x+2=145.2025$
$0.001x=143.2025$
$x=\frac{143.2025}{0.001}=143202.5$
Test the solution:
$p=42-\sqrt {0.001(143202.5)+2}=42-12.05=29.95$