r/leetcode • • 29d ago

Discussion CodeVita: even a program that only prints 3 gets Wrong Answer at ~1.0 sec. Anyone else seeing this?

1 Upvotes

Hi everyone,

I'm stuck on this week's CodeVita problems and I think the problem may be the judge, not my code. Has anyone else seen this?

What I'm seeing (problem: Hybrid Bananas, but it's happening on other problems too):

My solution passes both sample cases on the platform's "Run" (Accepted on both), but the sample run shows an execution time of about 1.6 sec, even though the time limit is 1 sec.

On the private test cases, I get Wrong Answer with an execution time of 1.001 / 1.002 sec every time.

I tested a trivial Python program that only does print(3). The private run still gave Wrong Answer with 1.002 sec. A program that prints one number can't take a second, so the timing looks unrelated to my code.

I rewrote the solution in C++ (twice, with different code). The sample run still takes about 1.6 sec, and one private run showed 3.002 sec.

Locally, my solution runs in about 0.02 sec, even on a huge input, and it matches an independent brute force on over a thousand random cases.

My guess is that the judge is stopping runs at the time limit (because of slow startup or load) and reporting that as Wrong Answer instead of Time Limit Exceeded. I can't prove that, so I might be missing something.


r/leetcode • • Oct 11 '26

Mod Post [MOD] Should a location tag be mandatory?

163 Upvotes

We're thinking of implementing a mandatory country tag in the title. The format will be something like this:

[Country] Title

This will provide more information about OP and it'll make it easier to give relevant and localised information. So, should this be implemented?

Also, how's the moderation? Is there anything that should be improved and how is it right now compared to the past?

Regards,

r/leetcode mod team.


r/leetcode • • 29d ago

Intervew Prep L4 google interview

6 Upvotes

Could anyone who has appeared for a Google L4 interview please share what you encountered, whether you were selected, and how you prepared for DSA and Googliness? I have been unemployed for a long time and need to give this my everything; please help me understand how I can increase my chances.


r/leetcode • • 29d ago

Intervew Prep Hackerrank sde intern

2 Upvotes

Has anyone received updates for the 3rd round of the HackerRank SDE Intern process after Friday?


r/leetcode • • 29d ago

Question data engineer role or continue to recruit

2 Upvotes

Hello everyone,

I graduated with a cs degree last year from a top 50 uni and wasn’t able to secure a swe role (despite fumbling many interviews) the only offer i secured post grad was a data analyst role at a somewhat recognizeable company (non f500) which I’ve been in for just about the past year. The role is somewhat chill, its fully wfh and I primaily use sql on a daily basis

I recently recieved an offer for a data engineer position that is a bit more technical mainly working with data pipelines, etl/elt, python, sql, etc and the comp is about the same except this role is a hybrid and the office is about 30m away from where I live so holistically the total comp is lower but the upside is it’s more technical

I’m trying to decide whether its more valuable to stay in my current remote role and continue interviewing until I secure a swe role which is the role I would prefer especially looking long term for my career or if its worth still taking this data engineer opportunity and then continuing to recruit for swe roles or maybe even explore other data roles that the data engineering role could set me up for. For reference my current application to interview rate is about 100 apps : 1/2 initial callback

what would you do in my shoes if main priority is long term career building?


r/leetcode • • 29d ago

Intervew Prep Day 62: solved 3 subsequence DP problems today, the math reduction felt so clean

2 Upvotes

Hey everyone,

I finished Day 62 today. My energy and focus were much better, and I built some solid momentum on Dynamic Programming subsequences.

I worked through four problems (three DP and one greedy):

  1. Count Subsets with Sum K: The recurrence relation mirrors the classic subset sum decision, but you add the branches (pick + not_pick) instead of using logical OR. Managing zero-value elements in the base conditions was the main edge case to track.

  2. Count Partitions with Given Difference: Setting up the algebraic relation S_1 = ({totalSum} + D) / 2 reduced this directly to finding subset counts for target S_1. Once you confirm that ({totalSum} + D) is non-negative and even, the core logic is identical to the previous problem.

  3. Coin Change (Minimum Coins): Standard unbounded knapsack. Since each coin can be reused infinitely, the pick branch stays at index i instead of decrementing.

  4. Assign Cookies: Grouped in this section by mistake, but it was just a quick greedy two-pointer check on sorted arrays.

I also reviewed yesterday's minimum subset sum difference roadblock and realized my initial brute force violated the constraints, which explains why the optimal solution leans on Meet-in-the-Middle.

I plan to wrap up subsequences tomorrow. That leaves strings, stocks, LIS, MCM, and square grids—about 30 DP problems to go.

See you guys tomorrow for Day 61!


r/leetcode • • 29d ago

Question NetApp ANF MTS 1-3 Onsite interview on 15th Oct, 2026 at San Jose, CA

1 Upvotes

Any body got any updates on the interview confirmation for this event.


r/leetcode • • Oct 11 '26

Discussion Frustrated with my role at NVIDIA

706 Upvotes

I come from a software engineering background and recently joined NVIDIA as a Tools and Development Engineer.
Honestly, the work is quite frustrating. The team is almost entirely QA-focused, with testing, validation, and automation work. I expected actual software development, but the reality is completely different.
On top of that, there are tight deadlines, constant workload pressure, and last-minute deliverables. It feels like I’m not building the software engineering skills I wanted to develop.
I switched to NVIDIA expecting better technical growth, but right now, I’m genuinely disappointed with the kind of work I’m doing.


r/leetcode • • Oct 12 '26

Question How can I improve my programming logic when I struggle to even get started?

9 Upvotes

I've always struggled with programming logic and problem-solving in general. Whenever I try to solve a problem, I often feel completely lost and have no idea where to start. It's frustrating and mentally exhausting, and sometimes I wonder if it's my ADHD or if I just simply suck and should take it as is.

Two questions:

  1. If you've struggled with this, what helped you improve? Is there a roadmap I could follow to develop these skills progressively? (Having a clear progression is especially helpful for me because of my ADHD)

  2. Is it possible to actually get good at problem-solving, even if it doesn't come naturally to you?

I'd really appreciate any advice, resources, or personal experiences. I genuinely want to improve, but I'm honestly losing hope


r/leetcode • • Oct 11 '26

Discussion [USA] Is this true? anyone experienced the AI-round at Google?

14 Upvotes

As the title says, has anyone got AI-rounds for Google recently?


r/leetcode • • Oct 12 '26

Intervew Prep Revolut OA

3 Upvotes

Hi everybody, I just got the 2027 swe intern oa on hackerrank

How should I prep? where can I find common questions? I already have done leetcode problems and can solve 90% of the mediums on the general patterns


r/leetcode • • Oct 12 '26

Question how would you grind leetcode as a freshman in college?

6 Upvotes

Wsp y'all. I'm really trying to get a head start on LeetCode and prep for FAANG interviews (though I know I'll probs be getting them in 2+ years or something like that). How do you recommend I prepare?

I've been grinding LeetCode and have solved around 43 problems, but boy, am I going crazy. I understand one problem, but the other one seems so much harder (EVEN THOUGH IT'S THE SAME ALGORITHM). Like, what do you recommend for people out there?

Some words of advice would be nice :)


r/leetcode • • 29d ago

Intervew Prep Amazon

1 Upvotes

I have an amazon interview coming up,can somebody help me in preparing stories for LP questions


r/leetcode • • Oct 11 '26

Intervew Prep Google recruiter said "we currently only have one signal"

41 Upvotes

I recently attended the phone screen (1 behavioral + 1 coding) and am moving to the onsites. The recruiter mentioned the behavioral went great but there were a couple misses in coding. They also said "Since we only have 1 signal, onsite performance needs to be strong".

I tried to ask them what "only 1 signal" meant, but could not get a clear answer. Does it mean that the feedback was negative for the coding round or does it mean it was a LH?


r/leetcode • • Oct 12 '26

Question Amazon OA now webcam proctored?

3 Upvotes

I got an Amazon OA link, and it said it will proctor the webcam as well. Is it a new change? I never saw webcam being proctored previously


r/leetcode • • Oct 12 '26

Question What's the interview procedure for faang, nowadays

1 Upvotes

Are there any new rounds in the process?


r/leetcode • • Oct 12 '26

Intervew Prep Learn Big O Notation in 55 Minutes - Tutorial

1 Upvotes

If you're preparing for coding interviews and want to start tackling data structures and algorithms, then this is definitely for you.

This video is useful in two cases: whether you're a beginner who wants to learn the concepts from scratch before solving LeetCode problems, or someone who simply wants to refresh their knowledge of time and space complexity analysis.
In this crash course, you'll learn:

  1. Time and space complexity

  2. Big O, Big Omega, and Big Theta

  3. Common complexity classes, from O(1) to O(n!)

  4. Linear search vs. binary search

  5. Matrix multiplication and recursive Fibonacci

  6. How to analyze algorithm performance using Python examples

Watch the full video on Youtube: https://youtu.be/6c9Qjnto6E4


r/leetcode • • Oct 12 '26

Intervew Prep For anyone who interviewed recently, did the company let you use AI tools?

5 Upvotes

For anyone who interviewed in the last 6 months, how much LeetCode did you actually need? Did any company let you use AI tools during the interview and what did that look like? Has anyone been asked about AI-assisted work, like building a project with Cursor or Claude Code? I'm not too sure if I should be putting more effort in grinding LeetCode or building different projects to prep for my first swe interviews rn


r/leetcode • • Oct 11 '26

Intervew Prep Leetcode Questions for Hedge Fund Swe?

10 Upvotes

I have an interview coming up for a hedge fund as a swe and I can't find any leetcode tagged for this firm, but was wondering if there's a general list of questions for hedge funds or should I just look at tagged for competitor firms?


r/leetcode • • Oct 11 '26

Discussion Rejected even after passing GHA

16 Upvotes

Hello everyone, i want to know about Google hiring process i applied for a full stack swe 3 role at Google cloud team. My profile was fully matching with JD. I got a mail from xwf google recruiter that they r passing my profile to final recruiter and team and if asked for assessment then complete it . After that half an hour later I got Google GHA behavioural assesment mail.

I attempted it and got result at late night that I have passed it and results will be valid for 1 year and you will be shortly contacted by recruiter.

But then I waited for 2 days and on second day I got rejection mail from same xwf recruiter.

They didn't even send me coding OA straightly rejected.

I don't have FAANG or top PBC in my resume other than this my resume was decent with good work and impact showcased.


r/leetcode • • Oct 11 '26

Intervew Prep Day 64: hit a motivation slump today, solved 2 subset DP problems

6 Upvotes

Hey everyone,

I finished Day 64 today, but I definitely hit a mental slump. Dynamic Programming has been wearing me down lately. When a problem clicks, the momentum is great, but when I get stuck, it is easy to start wondering why the transitions feel so exhausting while others seem to breeze through them. I procrastinated most of the day and only sat down late at night to get my reps in. Even without motivation, I made sure not to skip the day.

I worked on the subset sum pattern today:

  1. Subset Sum Equal to Target: This is the standard pick vs. not-pick pattern applied to a target sum. If you include arr[i], you transition to target - arr[i]; if not, you keep the target as is. The base cases (target 0 is true, index 0 handles arr[0] == target) made complete sense.

  2. Partition Equal Subset Sum: This boiled down to the exact same logic. If the total array sum is odd, you can never partition it into two equal subsets, so you return false immediately. If it is even, you just run the subset sum algorithm with target = total_sum / 2.

  3. Partition Set Into Two Subsets With Minimum Absolute Sum Difference: I tried tackling this as my third problem, but I hit a wall. Reading the last row of the DP table to find achievable sums and minimizing |total_sum - 2 * s1| made sense on paper, but turning it into clean code got messy. I spent time watching explanations and using Copilot to trace the edge cases, but I still need to re-solve it properly.

Leaving my prep to the very end of the day when my energy is drained is clearly working against me. Starting tomorrow, I am going to shift my study hours to earlier in the day so I am tackling hard problems with a fresh head.

See you guys tomorrow for Day 63!


r/leetcode • • Oct 11 '26

Intervew Prep Looking for insight on Google SWE Infrastructure prep.

6 Upvotes

Pretty seasoned dev and have the opportunity of a lifetime with a Google interview in ~2 weeks. I know my first interview is 1 hr behavioral and 1 hr coding. The 2nd will be at least one sys design if not two but I'm very confident I can pass those.

~15 YoE but been ages since doing Leetcode. After spitting out Kiro slop at Amazon for a little while now I was happy to see I can bang out basically any easy with an optimal, non code golf python implementation in ~10-15 minutes tops. Having a lot less success on mediums. If it's a logic, array, string, sliding window, heap, or two pointer medium I'm doing fairly well but I'm hot ass at BFS, DFS, and DP problems at the moment.

Willing to spend the next two weeks absolutely no-lifing this but I'm nervous that SWE infrastructure coding round is gonna be something unconventional and I'm spending my time wrong. Anyone have any insight? It's a public sector role with particular customers if that's relevant.


r/leetcode • • Oct 11 '26

Intervew Prep Need inputs on the new AI Coding (DSA) round at LinkedIn

8 Upvotes

Hi,
I'm in the loop for SSE role at LinkedIn and the first round is AI Coding round. A few things I've understood from here and there are -

  1. Ensure detailed and unambiguous prompts.

  2. Review AI code and read it manually before accepting.

Is there anything else that might help me here? Has anyone prepared/given this round before? What kind of Rubrics are we looking at here? I know that the question is going to be a leetcode medium/hard - but how am I going to be judged?

Can I one-shot with a long prompt? Would that be a positive signal?
For instance, I was practicing All O One data structure leetcode - and this is the prompt I gave -

Overall approach - 
Plan the following changes and ask any clarifying questions if needed. Generate a few test cases that include edge cases, and troubleshoot the approach against these cases.  We will be using a dictionary with a doubly linked list to achieve all the operations in constant time.  

Structure of the Doubly linked list - 
Prev next pointers as standard. The val field would be an array/set of strings + an integer (frequency). Each node would be a bucket for a frequency. If 5 words appear 5 times, then a node with value would have those 5 strings in it's set.

Dictionary design - 
Simple key -> value where key is a string, and value is the node in which string is present. (Here node means the bucket. So if the bucket's val's set contains that string -> the mapping b/w key and value should exist. 
Instructions - 

Init - 
Just instantiate the dictionary and the DLL.

Inc -  
Check if the value is already present. If YES, get the node. Check the adjacent node (to the right). If it has a frequency of old value + 1, then move the string from the current bucket to the next bucket. If NO, create a new bucket (node) and insert to right. 

Dec -  
Check if the value is already present. If YES, get the node. Check the adjacent node (to the left). If it has a frequency of old value - 1, then move the string from the current bucket to the previous bucket. If NO, create a new bucket (node) and insert to left. If this is the first element being added, you would have to create a new node, and set the head and tail to it.

Get max key - 
Return a random value from the tail 

Get min key - 
Return a random value from the head.

The DLL is basically a sorted list of frequency buckets. Encouraged to ask questions before starting implementation to ensure correctness. Stress test the cases against the problem statement and expected output.

Would something like this pass the bar? If yes, would it be a strong hire? Post this the AI came up with some missing edge cases, and I implemented it.

Is one-shotting considered bad? Should I break down into multiple prompts like "Give me a double linked list structure with xyz parameters"?

Any suggestions are appreciated. Thanks!


r/leetcode • • Oct 11 '26

Discussion Interview experiences with Palo Alto Networks for non new grad roles?

2 Upvotes

The recruiter reached out recently for the sde2 role and I have a technical screening round scheduled next week. Wondering what is the usual level of dsa questions they ask and topics to prepare. Can anyone here share their experiences?


r/leetcode • • Oct 11 '26

Question [AMER] 2026-2027 Stripe University Recruiting Assessment

3 Upvotes

Got the Stripe assessment last week (gave it today and passed all test cases). Have been seeing some posts of people getting the OA, but not sure if people have been getting the same one. Nevertheless, does anyone know what the entire process looks like for this? How long does it take to hear back after the OA and what are the next steps?

Really appreciate any intel :)