I'm trying to introduce a friend to competitive programming. He is an engineering student who enjoys the sort of problems we have here on Codeforces, but he did not study CS and is lacking a lot of the basics most of us take for granted. He knows how to program (in Python) but doesn't know a lot of the algorithms 101 topics, such as a strong grasp of computational complexity, sorting algorithms, or even some basic data structures like hashtables and binary trees.
I know some good texts that can help those who have this fundamental knowledge (primarily Laaksonen's book), but what's the best way to introduce someone who lacks any formal CS education?
I'm especially looking for books or websites that he can use by himself.
No python plebs allowed.
As an electrical/electronics engineering student, I think I'm qualified to answer your question. First of all I don't think a formal CS education, which mostly consists of only theoretical courses, is even required to do cp. I started cp because I enjoy doing it and whatever I learnt, I learnt online. There are so many amazing resources like geeksforgeeks, cp-algorithms, cf blogs and great tutorials from youtube.
Coming to how to get started, I started off by doing Long challenge in codechef, which kinda introduced me to stl and now I've been concentrating on cf because of the amazing variety of problems offered. All in all I suggest you ask your friend to start doing cp rather than learn some books because cp is mostly 'learning by doing' more than anything else.
I agree to an extent. There's certainly a ton of material that is very theoretical and doesn't help with competitive programming at all (and arguably any sort of programming or practical skill). But if you lack really basic knowledge (like good understanding of computational complexity, or basic data structures) then you will have a very hard time trying to start CP. CP basically assumes this type of knowledge, and as someone with zero CS exposure, you'd just fail repeatedly without understanding what knowledge you are missing or how to obtain it.
There's also a ton of mistakes and problems in many of these resources. So many articles on geeksforgeeks are confusing or just plain wrong.
It's hard to find high quality tutorial resources anywhere.
On YouTube, I know of Algorithms Live! which is good, but is not a tutorial. Did you ever watch a tutorial video that was actually good, clear, correct, etc?
Literally the only knowledge required to get started with cp is to know to initialize arrays, write loops and have some knowledge on sorting. Most of the div2A,B can be solved using just this considering one has enough practice. I do agree getting to know of the basic data structures, complexity, stl etc are important even for beginners but learning these while doing has much more impact in the understanding than just learning it with no basic knowledge.
Coming to resources from youtube, you clearly are not searching well enough if you don't find anything good. Let me list a few:
I'm trying to introduce a friend to competitive programming.
Please don't. Don't waste your friend's time. Your friend has lots of stuff to learn about being an Engineer already. Time is too precious to waste on unnecessary stuff.
Try getting all sports fans, or fans of anything, to not share their interests. It's only natural for people to share what they like, and if others want to do it too or not, they can do as they please.
Whenever there exists some stupid or irrelevant or rude comment in a blog, why does it always have to be yours?
What the fuck is wrong with this community? The author asked a perfectly fine question even with info that Laaksonens' book is there but maybe there's a better way for someone without CS background. This should actually be an example of how to ask questions and instead, it's downvoted.
The CS background isn't necessary as many people start with CP in high school. This means that you can just search for all the "how to start with CP" questions and tutorials.
CPH is a very good choice, along with solving easiest problems in Atcoder Beginner Contests and Leetcode (which is very python-friendly).
I literally typed "How to" in the search bar and found this: https://mirror.codeforces.com/blog/entry/16599 https://mirror.codeforces.com/blog/entry/49157 https://mirror.codeforces.com/blog/entry/23054
Maybe you just got used to helping people that don't try to help themselves.
What are you trying to say with your links? That questions like "how to start" or "how to practice" are already answered? Sure. But OP asked a unique question "what about lack of CS background" and maybe a good answer would be "go through some cs course like one from MIT". He didn't know that and searching wouldn't likely help him. I still think that the question was perfectly fine and the answer is "CS background isn't necessary so follow any how-to-start CP" advice.
Wow, now I'm downvoted. Sure, just someone please explain to me MetB's comment. Or tell me why it's stupid to have a conversation about starting CP without cs background.
Because you don't need CS background when starting CP.
So the question "what should I do if X?" is stupid if the answer is "X doesn't change anything"?
It is not in general but the case is, "How does one start CP if (s)he has no CS background" kinda sounds like "How does one buy food if the fridge is empty", since X here is an obvious factor and everyone assumes the beginner has no CS background. Even if that's not obvious for the beginner himself, trying to find previous similar topics, I'm sure, would lead to about the same blogs I mentioned, where no previous knowledge is presumed. As I said, most likely people ask without properly trying to find answers themselves.
I would say that most of beginners in CP already know programming / CS.
it's stupid that the blog starts getting upvotes because of errichto's comment. people can't really think for themselves, they need a grand master as their Shepard.
I am a Bachelor of Commerce student who transitioned to computer science through self-study. I was introduced to CodeChef by my brother, and after finding a challenging problem, I became hooked. The rest is history.
This is interesting. Can you tell us more about your journey? How you practiced, how you made time among all your academic studies, what hurdles you faced etc.?
TIA!