Because of the part of the passage that states,
"For if I had existed alone and independent of all other, so that I had of myself all this little whereby I participated in the Perfect Being, I should have been able to have in myself all those other qualities which I knew myself to lack."
I believe that you are correct and the answer is D. The best inference from the passage is that God must exist because otherwise Descartes, as an imperfect being, would have no knowledge of the idea of perfection.