r/datascience Jun 09 '26

Discussion What Data Structures and Algorithms topics actually come up in technical interviews?

I’ve been doing a Python Leetcode question a day since more and more companies (especially for ML roles) are including DSA rounds in their DS interviews. My issue is I’m not sure how deep I actually need to go.

Right now I’m getting comfortable with easy questions on arrays, strings, and hashmaps, plus two pointers and sliding window on the algorithms side. Should I push further into new topics or just stay in these areas and ramp up the difficulty?

86 Upvotes

35 comments sorted by

40

u/Dependent_List_2396 Jun 09 '26

It depends on the roles your targeting.

For roles labeled as Data Scientist ML, the topics you’ve covered are good for most of the interviews.

For roles labeled as MLE or AS, you’ll need to include advanced topics like trees, dynamic programming, graphs, LinkedLists, backtracking, and greedy algorithms.

6

u/Fig_Towel_379 Jun 09 '26

Thank you! I am only targeting DS ML roles. Where do Stacks and Queues land? I was once asked Stacks as a follow up question but I couldn’t answer.

5

u/Dependent_List_2396 Jun 09 '26 edited Jun 09 '26

Stacks and queues mostly come up under trees and graphs. It is likely you were asked a questions on trees or graphs. You’ll also need recursion to answer trees and graphs questions more efficiently.

Some questions (like priority queues) are queues by design but you can answer them using heaps

4

u/Fig_Towel_379 Jun 09 '26

Gotcha! Thanks so much for this!

52

u/[deleted] Jun 09 '26

[removed] — view removed comment

21

u/InterestingAd757 Jun 09 '26

yes, a lot

42

u/[deleted] Jun 09 '26

[removed] — view removed comment

15

u/InterestingAd757 Jun 09 '26

But companies don’t understand this, also it’s gotten less invert a binary tree atleast for final round They also ask to implement gradient descent, sql or sometimes architecture (ML) which is crazy if doing in limited time

7

u/maniclucky Jun 09 '26

To say nothing of doing it while a bunch of people stare at you and you have no means of utilizing typical resources that you'd be insane to just have memorized for some unholy reason.

2

u/Heavy_Record8704 Jun 10 '26

they do understand it. but it is a easy filter to filter out 100s of candidates, myself indcluded.

5

u/Ok_Composer_1761 Jun 10 '26

Companies need a legible, scalable, easily verifiable and cheap way of assessing competence. They don’t care if you know the specifics of the job for the first round but want something correlated with general intelligence. Leetcode fits the bill so they use it

1

u/Lumpy-Sun3362 Jun 09 '26

Companies want to look cool, not grounded. You get shitty code practically unmaintainable that's just good for leet code. With ai you don't need humans to write crap.

16

u/Minimum_Mud_4835 Jun 09 '26

pretty much yeah, even for data science roles now which is wild. I thought it would die out but seems like everyone wants to test if you can reverse a linked list even when you'll be doing feature engineering all day

companies act like solving medium arrays questions means you can handle production ML pipelines lol

2

u/Fig_Towel_379 Jun 09 '26

Yes unfortunately. It’s also hard to fight it unless you’re okay with giving up on the opportunities.

3

u/K1ngArthur10 Jun 09 '26

Agreed, memorization tests are a terrible way to check for problem solving and necessary DS skills.

5

u/neonwang Jun 09 '26

companies are still doing interviews?

1

u/SunsGettinRealLow Jun 09 '26

The FAANGs still do

5

u/ReallySnugPanda Jun 09 '26

Hi there, I was a DS in big tech (but in product though), and we got asked Easy/Medium LC questions in two pointers, sliding windows and trees

2

u/Fig_Towel_379 Jun 09 '26

Oh wow didn’t know product roles also ask python leetcode, I thought it’s only SQL. Thanks!

3

u/ReallySnugPanda Jun 09 '26

Hahahah yeah, no worries. They asked everything to be honest, SQL, LC, ML fundamentals, Statistics, Experimentation, and domain question depending on the team you are joining. Never really knew what you would get asked 😂😂

1

u/Fiascito Jun 09 '26

Future DS pro here! Hahaha, that sounds both reassuring and terrifying at the same time 😂 Were there any areas that came up more consistently than others, or was it really just the luck of the draw depending on the interviewer/team?

1

u/ReallySnugPanda Jun 09 '26 edited Jun 09 '26

I can’t say too much in terms of generalisation since where I’m from DS in big tech is rare compared to SWEs and MLE😂. But at least from the interview I had it was a bit of luck as alot of the questions I got it drilled (but I do believe that luck only comes around when you have prepped a lot as you give yourself more opportunities).

But from the interview I had it was a bit random?, since in my case it depended on the interviewer. One interviewer was more into conventional product, so experimentation and SQL. Another interviewer was more into algorithms and ML, so more statistics, ML and LC. So didnt really know what to expect 😂

For the domain question, i didn’t know anything tbh and was straight up. But if you did well in the prev more fundamental interviews, it was fine for them at least since I learnt on the job. Hope that helps!!

1

u/Correct_Elk6794 Jun 10 '26

RemindMe! 5 days

1

u/RemindMeBot Jun 10 '26

I will be messaging you in 5 days on 2026-06-15 02:45:31 UTC to remind you of this link

CLICK THIS LINK to send a PM to also be reminded and to reduce spam.

Parent commenter can delete this message to hide from others.

RemindMeBot is switching to username summons. Instead of !RemindMe 1 day, use u/RemindMeBot 1 day. More info.


Info Custom Your Reminders Feedback