Confusing!

So I recently started the pill (like just a few days ago). How long should it take for it to start working? And is it safe to have unprotected sex but pull out when on the pill? Sorry its just quite confusing for me to remember everything about birth control ha.