practice a little every day, paws crossed ♡
Software Engineer Interview Questions
Practice 9403 coding, system design and machine learning questions from 546 companies, sorted by role, topic and interview round. Every question has step-by-step hints, a code runner that supports 8 languages and an AI mentor; members also get the full solution walkthrough.
- 9403
- Questions
- 546
- Companies
- 11
- Topics
- 8
- Languages
Showing 1261–1290 of 2629 results
- LinkedInEasySoftware EngineerDebug Queues and Solve Arrays
Tests array traversal, sliding window techniques, and handling wrap-around logic in circular data structures with edge cases.
Coding & AlgorithmsOnsiteArraySliding WindowTwo Pointers - LinkedInEasySoftware EngineerDesign O(1) Randomized Multiset
This problem tests your ability to design a data structure that supports efficient insertion, deletion, and uniform random sampling by combining dynamic arrays with hash maps to achieve constant time complexity.
Coding & AlgorithmsTechnical ScreenHash MapArrayDesign - LinkedInMediumSoftware EngineerDesign a Randomized Multiset
This question evaluates the ability to design and implement a randomized multiset that correctly handles duplicate integer occurrences while providing expected O(1) insert, remove, and uniform getRandom operations, testing knowledge of data structures, randomness, and performance constraints.
Coding & AlgorithmsTechnical Screen - LinkedInMediumSoftware EngineerDesign a max-stack with efficient operations
This interview question evaluates algorithm design, data structures, correctness, complexity, edge cases, and implementation details in a realistic interview setting. A strong answer for Design a max-stack with efficient operations states assumptions, handles edge cases, explains trade-offs, and shows how to validate the result clearly.
Coding & AlgorithmsOnsite - LinkedInMediumSoftware EngineerDesign a stack with max removal
This question evaluates data-structure design and algorithmic complexity analysis by requiring a stack-like structure that supports standard stack operations plus efficient maximum retrieval and targeted removal, assessing practical implementation skills and time-complexity reasoning at a practical application level.
Coding & AlgorithmsTechnical Screen - LinkedInMediumSoftware EngineerFewest-Edge Distance Between Two Nodes in a Directed Acyclic Graph
Given a directed acyclic graph and two nodes, return the fewest edges on a directed path from the source to the target, 0 when they are the same node, or -1 when the target cannot be reached. Asked as a follow-up to topological ordering, it tests traversal of dependency graphs.
Coding & AlgorithmsOnsite - LinkedInMediumSoftware EngineerFind a Target's Index in a Rotated Sorted Array of Distinct Integers
Find the index of a target value in an array of distinct integers that was sorted ascending and then rotated at an unknown pivot, returning -1 when it is absent. Tests adapting search to a partially ordered array in logarithmic time and handling unrotated and single-element inputs.
Coding & AlgorithmsOther - LinkedInMediumSoftware EngineerFind dictionary words matching a phone digit string
This problem tests your ability to map phone keypad digits to characters and efficiently filter a provided dictionary to find words that match a specific digit sequence.
Coding & AlgorithmsOnsiteStringHash TableTrie - LinkedInEasySoftware EngineerFind dictionary words that match a phone keypad digit sequence
Coding problem: given a list of known words and a digit string typed on a standard phone keypad, return every known word whose letters map to exactly that digit sequence, in sorted order. It tests string encoding, choosing a lookup structure for the dictionary, and analyzing time complexity.
Coding & AlgorithmsTechnical Screen - LinkedInMediumSoftware EngineerFind lowest common ancestor
This question evaluates understanding of binary tree structure, lowest common ancestor concepts, and competency in algorithmic reasoning and tree traversal within the Coding & Algorithms category.
Coding & AlgorithmsOnsite - LinkedInMediumSoftware EngineerFind the K Closest Values in a Sorted Array
This problem tests binary search and window optimization to find the k nearest elements to a target in a sorted integer array.
Coding & AlgorithmsOnsiteBinary SearchTwo PointersArrays - LinkedInMediumSoftware EngineerFind the K Values Closest to a Target in a Binary Search Tree
Given a binary search tree described by its preorder traversal, a real-valued target and an integer k, return the k node values closest to the target in ascending order, breaking distance ties toward the smaller value. Tests binary search tree traversal, reasoning over ordered data and precise tie handling.
Coding & AlgorithmsOnsite - LinkedInMediumSoftware EngineerFind the Maximum Depth of a Binary Tree
Find binary-tree depth from a portable child-index representation, including empty trees and highly unbalanced root-to-leaf paths.
Coding & AlgorithmsOnsite - LinkedInMediumSoftware EngineerFind the Node Where Two Singly Linked Lists Merge
Two singly linked lists stored in one successor array may merge at some node and share every node after it. Given both heads, return the first shared node, or -1 if the lists never meet. It tests linked-list traversal and careful handling of cases such as one list starting inside the other.
Coding & AlgorithmsTechnical Screen - LinkedInMediumSoftware EngineerFind the k-th largest element in an array
This question evaluates proficiency with selection algorithms, array manipulation, and analysis of time and space complexity, reflecting competency in order-statistics and basic data structures.
Coding & AlgorithmsOnsite - LinkedInMediumSoftware EngineerGenerate All Distinct Permutations of a List with Duplicate Values
Given a list of up to eight integers that may contain duplicates, return every distinct permutation exactly once, sorted in lexicographic order. It tests systematic enumeration, avoiding duplicate results caused by equal values, and producing a deterministic output order.
Coding & AlgorithmsTechnical Screen - LinkedInMediumSoftware EngineerImplement Fast Power with Negative Exponents
This problem tests your ability to implement the exponentiation by squaring algorithm while correctly handling edge cases like negative exponents and integer overflow.
Coding & AlgorithmsOnsiteAlgorithmsMathBit Manipulation - LinkedInMediumSoftware EngineerImplement an LRU cache with follow-ups
This question evaluates understanding of core data structures and algorithms for designing an efficient LRU cache as well as knowledge of concurrency and synchronization for thread-safe access.
Coding & AlgorithmsOnsite - LinkedInMediumSoftware EngineerLargest Sum of a Non-Empty Contiguous Subarray
Given an integer array, return the largest sum of any non-empty contiguous subarray, including arrays in which every number is negative. This classic phone-screen problem tests efficient array processing and careful handling of edge cases such as all-negative input.
Coding & AlgorithmsOnsite - LinkedInMediumSoftware EngineerLexicographically Smallest Topological Order of a Dependency Graph
Given n labeled nodes and directed precedence edges, return an ordering that respects every edge, choosing the lexicographically smallest valid ordering, or an empty list when a cycle makes ordering impossible. It tests topological sorting, cycle detection and deterministic tie-breaking.
Coding & AlgorithmsOnsite - LinkedInMediumSoftware EngineerLongest Run of Ones After One Flip
This problem tests your ability to manage a sliding window with a flexible constraint, specifically counting zeros to determine the maximum length of a sequence after a single modification.
Coding & AlgorithmsTechnical ScreenSliding WindowTwo PointersArray - LinkedInMediumSoftware EngineerMaximum Product of a Contiguous Subarray With Negatives and Zeros
Given an integer array that may contain negative numbers and zeros, return the largest product of any non-empty contiguous subarray. The problem tests careful reasoning about sign changes, zeros and single-element subarrays under tight input-size limits.
Coding & AlgorithmsOnsite - LinkedInEasySoftware EngineerMerge Two N-ary Trees by Matching Node Keys
Merge two rooted n-ary trees in which every node has an integer key, combining nodes only when their keys match under matching parents. Tests recursive tree traversal, matching children by key, handling roots with different keys, and producing a canonical preorder encoding of the merged tree.
Coding & AlgorithmsTechnical Screen - LinkedInMediumSoftware EngineerMinimize adjacent-color assignment cost
This interview question evaluates algorithm design, data structures, correctness, complexity, edge cases, and implementation details in a realistic interview setting. A strong answer for Minimize adjacent-color assignment cost states assumptions, handles edge cases, explains trade-offs, and shows how to validate the result clearly.
Coding & AlgorithmsTechnical Screen - LinkedInEasySoftware EngineerMinimum index distance between two given words in a word list
Coding problem: given a list of words and two different target words that both appear in it, return the smallest distance between an index of one word and an index of the other. It tests single-pass scanning with position tracking, handling of repeated occurrences, and time complexity analysis.
Coding & AlgorithmsTechnical Screen - LinkedInMediumSoftware EngineerReverse a linked list
This question evaluates understanding of linked list data structures and proficiency manipulating pointers or references to perform in-place transformations when reversing a linked list. Commonly asked in Coding & Algorithms interviews, it gauges algorithmic thinking and practical application-level competency in list operations rather than purely conceptual theory.
Coding & AlgorithmsOnsite - LinkedInMediumSoftware EngineerSecond-Smallest Value in a Min Tournament Tree in Logarithmic Time
Given a full binary tournament tree stored in array order, where each internal node holds the smaller of its two children, return the second-smallest leaf value in logarithmic time. It tests reasoning about how a knockout structure constrains where the runner-up can be, array-based tree indexing, and justifying a partial search.
Coding & AlgorithmsTechnical Screen - LinkedInMediumSoftware EngineerShortest Substring Containing Every Character of a Pattern
Return the shortest substring of a string that contains every character of a pattern with matching multiplicity, case-sensitively, choosing the leftmost substring on ties and an empty string when none exists. Tests efficient substring search and careful character-count bookkeeping.
Coding & AlgorithmsOther - LinkedInHardSoftware EngineerShortest Word Distance Queries
Tests designing an inverted index and using two-pointer or binary search techniques to efficiently compute the minimum absolute index distance between word occurrences across repeated queries.
Coding & AlgorithmsTechnical Screenhash-tabletwo-pointersbinary-search - LinkedInMediumSoftware EngineerSolve Cache, Window, and Heap Problems
This question evaluates competency in advanced data structures and algorithmic techniques—specifically frequency-based cache design, sliding-window substring search, and heap-driven k-pair generation—along with time and space complexity analysis and robust edge-case handling.
Coding & AlgorithmsOnsite