Resources for beginners. I recommend to first know what computers are my going into detail and then learn a programming language.
Coursera is a platform where you can start off by learning about a programming language that you like. I recommend something popular such as JS, C++, Python, or C. Moving on, these are a set of instructions on how to get a course for free on coursera. click on the image
Keep in mind that these are my recommendations are there are some better ones out there too! Khan Academy and Coursera are the ones I like the most, however some other ones for beginners are Udemy, GeeksforGeeks, tutorialspoint, Giraffe Academy, CS50 by Harvard and others.
Resources for intermediates and advanced learners. I recommend to first decide what you want to do after the mastery of a language, such as competitve programming or DSA.
This course is by Princeton University in California. It is available on Coursera and consists of 2 parts about Algorithms. Algorithms Part I and Algorithms Part II.
Again, these are my preferred and there are some other ones that are better than the ones I recommend. Some of the other ones are LeetCode, CodeChef, Neetcode Roadmap, Codeforces, Codewars, and USACO Guide. These require practice and learning more about the topcis to be better and more successful at them!