CMIMC 2019 Power Problem 1.2

Prove that \mathrm{P} \subseteq \mathrm{NP}.