how long does...? please help!

how long does sperm stay inside you after sex? I had sex saturday night and eves just told me I have began my ferile window.. so I was just wandering is it possible to get pregnant a few days after you've had sex or is it insant and only if your fertile whilst having sex?