Coding & Algorithms Interview Questions

Practice 3,429 real Coding & Algorithms interview questions for 2026. Covers companies like Meta, Amazon, Google, Uber, and Microsoft. Real questions from actual interviews with detailed solutions — ideal for focused interview preparation. Coding & Algorithms interview questions are the single most common technical gate for software engineering roles and are used to evaluate problem framing, algorithm selection, complexity trade-offs, correctness, edge-case reasoning, and clear communication under time pressure. Expect this category to appear in early technical screens and repeatedly across onsite loops at companies that weight it heavily (notably Meta, Google, and Amazon). Interviews will test arrays and strings, trees and graphs, dynamic programming, hashing and two‑pointer techniques, and the candidate’s ability to test and optimize code in a shared editor. Prepare with timed mock interviews, practice in the same editor you’ll use live, and build a progressive schedule that moves from fundamentals to medium/hard problems; typical candidates invest several weeks to a few months of focused practice depending on seniority and target company.

3.4k Questions 368 Companies08.11.2026
Showing 20 results
Role
Shopify logo
Shopify
Medium
Data Scientist

Calculate Jaccard Similarity Score for Two String Lists

Scenario During pair programming, the interviewer asks you to compare two lists of merchant tags and quantify their similarity. Question Implement a P...

Coding & Algorithms
11
0
148 people solved
Aug 4, 2025
Google logo
Google
Medium
Data Scientist

Simulate Coin Flips to Determine Fairness via Empirical Distribution

Scenario You must test whether a coin is fair by simulation. Question Write code that repeatedly simulates n coin flips, records the number of heads, ...

Coding & Algorithms
6
0
60 people solved
Aug 4, 2025
Experian logo
Experian
Medium
Data Scientist

Design Algorithm for Longest Increasing Subsequence Length

Scenario Programming assessment and infrastructure panel Question Design an algorithm to return the length of the Longest Increasing Subsequence of an...

Coding & Algorithms
4
0
40 people solved
Aug 4, 2025
LendingClub logo
LendingClub
Medium
Data Scientist

Determine If Two Numbers Sum to Target

Scenario Live CodeShare Python/Java question during the same LendingClub interview assessing basic algorithmic fluency. Question Given an integer arra...

Coding & Algorithms
2
0
27 people solved
Aug 4, 2025
Apple logo
Apple
Medium
Data Scientist

Find Smallest Missing Positive Integer in O(n) Time

Scenario LeetCode-style algorithm phone interview Question Implement a function that returns the smallest missing positive integer in an unsorted inte...

Coding & Algorithms
4
0
51 people solved
Aug 4, 2025
Meta logo
Meta
Medium
Data Scientist

Optimize Oculus Data Streaming with Bandwidth Constraints

Scenario Algorithmic screening for Meta VR/AR teams covering Oculus data streaming and geometric optimization. Question Oculus: Given an array frame_s...

Coding & Algorithms
4
0
46 people solved
Aug 4, 2025
Amazon logo
Amazon
Medium
Data Scientist

Implement Python Function for Longest Unique Substring Length

Scenario Real-time text analytics service enforcing uniqueness constraints Question Implement a Python function returning the length of the longest su...

Coding & Algorithms
3
0
26 people solved
Aug 4, 2025
Amazon logo
Amazon
Medium
Data Scientist

Determine Length of Longest Unique Substring

Scenario Online assessment: coding portion that follows the SQL questions. Question Implement a function that, given a string s, returns the length of...

Coding & Algorithms
4
0
30 people solved
Aug 4, 2025
Amazon logo
Amazon
Medium
Data Scientist

Identify Number Pairs Adding to Target in Array

Scenario Coding round to identify all number pairs that add up to a target in an array containing duplicates. Question Given an integer array (may con...

Coding & Algorithms
26
0
84 people solved
Aug 4, 2025
Amazon logo
Amazon
Medium
Data Scientist

Solve Algorithmic Challenges in Online Coding Assessments

Scenario Online assessment requiring implementation of common algorithmic problems. Question Given an array of integers and a target, return indices o...

Coding & Algorithms
10
0
90 people solved
Aug 4, 2025
PayPal logo
PayPal
Medium
Data Scientist

Generate Bigrams Using Python List Comprehension and Zip

Scenario Live Python exercise: generate all bigrams from an input string and iteratively optimize the solution. Question Write a Python function that ...

Coding & Algorithms
8
0
57 people solved
Aug 4, 2025
Capital One logo
Capital One
Medium
Data Scientist

Critique and Test Python Preprocessing Utilities Effectively

Scenario Code review of Python preprocessing utilities (OutlierHandler and three Imputer classes) Question Summarize, at a high level, what the Outlie...

Coding & Algorithms
9
0
65 people solved
Aug 4, 2025
Capital One logo
Capital One
Medium
Data ScientistSenior+

Explain Shell Script Line-by-Line for Data Science Workflows

Scenario Technical screening for a Principal Data Scientist: reviewing shell script and Python classes Question Explain, line by line, what the provid...

Coding & Algorithms
58
0
110 people solved
Aug 4, 2025
Shopify logo
Shopify
Medium
Data Scientist

Identify Pirate Themes Using Similarity Score Algorithm

Scenario Engineering wants an automated way to spot custom themes that are probably just pirate themes in disguise. Question Write Python that takes t...

Coding & Algorithms
68
0
101 people solved
Aug 4, 2025
Amazon logo
Amazon
Medium
Data Scientist

Generate Synthetic Clickstream Data with Python Function

Scenario The analytics team needs to generate synthetic click-stream records to test a new reporting pipeline before real traffic arrives. Question Wr...

Coding & Algorithms
201
1
636 people solved
Aug 4, 2025
Amazon logo
Amazon
Medium
Data Scientist

Solve Search Insert Position Using Binary Search

Scenario Live coding round for an Amazon Applied Scientist position; candidate must solve LeetCode 35 (Search Insert Position) without helper librarie...

Coding & Algorithms
69
0
207 people solved
Aug 4, 2025
Amazon logo
Amazon
Medium
Data Scientist

Implement Reservoir Sampling; Analyze Time and Space Complexity

Scenario Process an unbounded stream of user IDs and maintain a uniform random sample of k users in memory. Question Implement reservoir sampling for ...

Coding & Algorithms
23
0
63 people solved
Aug 4, 2025
OpenAI logo
OpenAI
Medium
Data Scientist

Identify Bugs in Python Script for User Assignment

Scenario A simple Python script assigns users to experiment groups and triggers the free-trial offer. Question Inspect the script and list any bugs or...

Coding & Algorithms
27
0
86 people solved
Aug 4, 2025
Upstart logo
Upstart
Medium
Data Scientist

Find Minimum Path Sum in Integer Triangle

Scenario Tech interview round 1 – dynamic programming challenge Question Given a triangle of integers, find the minimum path sum from top to bottom. A...

Coding & Algorithms
6
0
22 people solved
Aug 4, 2025
Amazon logo
Amazon
Medium
Data Scientist

Determine Maximum Path Length in Directed Acyclic Graph

Scenario A backend service represents task dependencies as a directed graph; you need to understand how deep the longest dependency chain can get. Que...

Coding & Algorithms
22
0
76 people solved
Aug 4, 2025

Frequently Asked Questions

How difficult are Coding & Algorithms interview questions?
Difficulty spans a wide range: from quick easy warm-ups to multi-stage hard problems that require advanced data structures or algorithmic proofs. Most companies place a majority of live coding rounds at the medium level, with occasional hard questions used to distinguish senior candidates. Interviewers evaluate problem framing, algorithm choice, time/space complexity, clean implementation, and thoughtful testing under time pressure. Expect more conceptual depth at Google, more consistent medium-to-hard screens at Meta, and Amazon to mix coding with leadership signals. Leveling depends on role and seniority: entry-level focuses on fundamentals; senior roles emphasize design, optimizations, and tradeoffs.
Where does Coding & Algorithms appear in a typical interview loop, and which companies weight it most heavily?
Coding & Algorithms is usually the first technical hurdle: it appears in phone/online screens, followed by one or more onsite or virtual coding rounds during the loop. Typical sequences are a technical screen, two to three in-loop coding sessions, then system design or behavioral rounds. Companies that weight this category heavily include Google, Meta, and Amazon, where coding performance often determines whether you progress. Candidates commonly concentrate practice for weeks or months beforehand; most targeting large tech firms prepare intensively for 6–12 weeks, while some spend 3–6 months for deeper mastery or level changes.
How long should I prepare and how should I structure that preparation?
Plan focused, progressive practice over a realistic timeline. A practical structure is an 8–12 week block: weeks 1–2 solidify fundamentals and language fluency; weeks 3–6 target core patterns (arrays, trees, graphs, DP) with timed problem sessions and pattern tagging; weeks 7–9 emphasize mock interviews, end-to-end problem solving, and optimization tradeoffs; final weeks simulate real loops with full-length sessions and targeted weak-point drills. Candidates with less experience may extend to 12–16 weeks. Regularly review mistakes, practice communicating solutions aloud, and include at least one weekly mock interview with peer or coach feedback.
What key subtopics and patterns should I master for Coding & Algorithms interviews?
Master a consistent set of patterns and their variations: arrays and strings (two pointers, sliding window), hash maps and frequency counts, sorting and binary search, recursion and backtracking, dynamic programming, trees and traversals, graphs (BFS/DFS, shortest paths, union-find), heaps and priority queues, and greedy algorithms. Also practice complexity analysis, space-time tradeoffs, and writing bug-resistant code with tests. For higher levels, focus on amortized analysis, advanced graph algorithms, segment trees or Fenwick trees, and system-aware optimizations. Interviewers value reusable problem templates and the ability to generalize patterns to new prompts.
What are standout tips and common pitfalls to avoid in Coding & Algorithms interviews?
Start by clarifying requirements and constraints, then outline your approach before coding. Write a correct, readable baseline solution first, then iterate to improve complexity while narrating tradeoffs. Test with simple and edge cases, and handle nulls, off-by-one, and empty inputs explicitly. Communicate continuously; silence looks like confusion. Avoid premature optimization, overcomplicating solutions, or ignoring interviewer hints. Time management matters: if stuck, discuss alternate approaches and code a partial solution. Finally, practice mock interviews to reduce anxiety and build the habit of clear, structured explanations under pressure.

Explore more Coding & Algorithms interview questions

Jump straight to Coding & Algorithms questions at a specific company or for a specific role.

By company
By role