Many error conditions that cause a CEL will reset and turn off the CEL if the condition that caused it goes away for three restarts in a row. But it will still likely leave codes stored in the computer.
But if it was me, I'd pay a visit to an Advance Auto, Autozone, Pep Boys, O'Reilly's, whatever you have in your neck of the woods. Most of them will read the codes for you for free. Sometimes that's all you need to figure out what the problem is.
And the guys are right, practically everything causes a CEL. Including not getting the gas cap on tight. No, really.