What should i do??

So i just had sex last night & the boy didn't pull out i'm really anxious because it's been 24 hours and i haven't taken a pill yet. Do you think a morning after pill will still be effective?????