This is the kind of thing I'm talking about.
A FreeCodeCamp account presumably offers more functionality beyond just the newsletter, and the majority of people would sign up for that functionality and not the newsletter.
Yet, there is no way to opt-out directly, and you have to go through extra steps to do so after the fact.
This is also in breach of the GDPR which mandates that consent for non-essential data processing (marketing communications fall into that) should be opt-in (so pre-ticked checkboxes are already forbidden) and freely given (so there is no penalty for declining, you can’t refuse to open an account for them if they decline consent).
https://www.freecodecamp.org/news/privacy-policy/
> We'll ask you for your email address so you can use it to sign into freeCodeCamp, and so we can send you announcements and helpful programming-related links.
Essentially, this is an "opt-in" process because you are opting to create your account and you agree with the site policies.
Granted, I'm in no way a legal professional and I could be wrong about everything I said here. Corrections are welcome.