My Toyota Corolla had the code 0171 and then I changed the 02 sensor. I ran the car and then I had a Zero readout. Now it's 3 days later and the engine light is on again. What should I do ?

you tried the easy fix, there are dozens of things that can trip that code. Check for vacuum leaks first, and also clean the maf sensor as in this video https://www.youtube.com/watch?v=NWCKvU2FmDc&t=71s