I'm scared and possibly pregnant

I don't remember the last time I had my period but recently I had sex with someone and we used a spermicidal condom but when he finished and pulled out the condom wasn't on him it was just kinda hanging from my vagina and we don't know if he ejaculated in the condom or in my vagina, I'm only 18 I can't afford to get pregnant and I'm scared... What should I do???