Pregnancy

So last night my boyfriend and I had protected sex, and he pulled out along with the condom. I hadn’t had sex in a long time so it hurt a little. I’ve been having light cramps and am worried I might be pregnant because the fertilized egg may be attaching to the wall. Hence the pain. Or am I in pain because I haven’t done it for awhile? Idk should I be worried?