r/AskProgramming • • 3d ago

Algorithms Do u know algorithms?

Hii guys 🤘

I always have some troubles with algorithms and sometimes it makes me feel that programming it isn't for me. 😄

I'm a full-stack JS (React/Node) develor and I have 2.5+ years of experiecne. I've done a lot of features and made a lot of good decisions. I started programming when enrolled a uni and I'm obsessed with that from those days. I like full-stack cuz I always can do a full app without someone and I know the best practices for the both parts.

So I always hard with myself because of algos, I really don't have "mathematic thinking" and it makes me frustrated somtimes. I always think straightforward, I have not ideas how to solve a problem by a good way like from the other side yk. And I tried to solve some tasks on leetcode cuz an AI told me that it's just experience and I jsut need to know typicall patterns, and probably it helped a little but I couldn't change my mind and I gave up šŸ˜“ .

I rate myself around middle (beginner) but I really struggled with algos and I can't understand what's the problem - me or just experience. Cuz sometimes it affects on my job, for example when I need to create some algo it takes a while to write real good but not brute-force solution yk. šŸ˜–

One of my friend has such a good math thinking and I always compare myself with him, it's not so hard for him to find a way to solve some problem. He can resolve medium tasks on LeetCode without a lot of problems as me. Probably each medium task took a lot of my time. 😭

Guys how're ur deals with algos lmk pls. And pls share ur experience and stack. If u have some advice I'd be glad to give it from u. Thanks for advice šŸ™

Peace āœŒļø

0 Upvotes

9 comments sorted by

2

u/NotACockroach 3d ago

If you're working I wouldn't focus on trying to improve at algorithms unless you find it's specifically limiting your job. I think in most software jobs knowing some basic principles is useful so you don't accidentally introduce huge performance issues, and knowing how to select good algorithms from libraries is useful, but you rarely find yourself implementing advanced algorithms style solutions from scratch.

If you're interviewing, solving leetcode mediums is absolutely enough for the vast majority of companies. I recently applied and got offers at a variety of big tech companies and I don't think any of the coding interviews were harder than a leetcode medium. But you have to be fast. In my experience I need to be able to solve leetcode mediums in about 20-30 minutes. Most of the coding interviews I did were 45-60 minutes and asked effectively a leetcode easy, with a follow up that modified it to approximately a medium, and wanted tests, readable code, discussion of tradeoffs etc.

1

u/Ok-Explanation9697 3d ago

do u usually solve issues on LeetCode? And who are u (back. front. desktop)?

2

u/NotACockroach 3d ago

I'm a senior backend developer with 10 YOE. I do not touch leetcode regularly for the reasons mentioned in my first paragrph. I do a lot of leet code leading up to an interview.

Coding on a time limit while someone watches you is completely different from the real job. While companies aren't usually asking literal leetcode questions any more, I found it an effective way to drill my interview condition speed.

1

u/Ok-Explanation9697 3d ago

Okay. Got u. Thank uuu so much āœŒļø

2

u/Obvious_Mud_6628 3d ago

Just keep practicing. Imposter syndrome is getting to you.

The more you do it the more confident you'll become. Also understand that even tho algos are harder for you than others, you're probably better at other things than those same people. It's easy to identify our shortcomings so focus on your strengths too

As for writing it, you don't have to be perfect out of the gate. Make it exist then you can untangle/make it good. Practice practice practice.

You obv know what you're doing so be nice to yourself

1

u/Ok-Explanation9697 3d ago

thank u so much. Probably Imposter syndrom is getting u're right. Sometimes I can just forget and don't think about tht but when it's getting so close ahhh my mind is full about tht yk. For example I created this post cuz now I'm preparing an interview and today I prepared a section about algos 😄

2

u/DT-Sodium 3d ago

If you're a React developer, you are not expected to be competent at that kind of thing. React is a technology for people who have a very basic understanding of programming, and generally close to zero skill in software architecture.

1

u/Ok-Explanation9697 2d ago

But as I said I’m a full-stack. I also have experience with c++, c#, assembler
(MASM). Does it make sense?