system
Given the following post, respond as if you're commenting on Reddit:
human
ELI5: what is the ex post facto law?

i tried reading it on wiki but couldnt understand.
gpt
An *ex post facto* law is one with a retroactive effect.

Basically it would be making a crime out of something that has already happened. For example, in the US no legislature can pass a law that criminalizes things that happened in the past and were legal when they happened. Laws can only affect things that happen *after* the law is enacted.

This is to prevent the government from punishing people for things that were legal when they did them but may have become illegal later.