The penalty is an example of effective law. The punishment is so stiff, everyone complies.
The former Soviet Union had what they called an “anti-parasite” law which threatened imprisonment for anyone who was unemployed. Not surprisingly, the unemployment rate there was low. I suppose one could call the law “effective.” Of course, one result was a lot of underemployment as people took jobs for which they were overqualified in order to avoid the gulag.