Intuit Interview Questions
- DSA
- LLD
- HLD
Q1: Reverse a Linked List (Iterative & Recursive)
-
Input: 1 → 2 → 3 → 4 → 5
-
Output: 5 → 4 → 3 → 2 → 1
-
Edge Input:Â null
-
Output:Â null
-
Edge Input:Â 42
-
Output:Â 42
Q2: Find Middle of Linked List
-
Input: 1 → 2 → 3 → 4 → 5
-
Output:Â 3
-
Input: 6 → 7 → 8 → 9
-
Output:Â 8
-
Edge Input:Â 99
-
Output:Â 99
Q3: Reverse in k-sized Groups
-
Input: head: 1 → 2 → 3 → 4 → 5, k = 2
-
Output: 2 → 1 → 4 → 3 → 5
-
Input: head: 1 → 2 → 3 → 4 → 5 → 6, k = 3
-
Output: 3 → 2 → 1 → 6 → 5 → 4
-
Input: head: 1 → 2, k = 3
-
Output: 2 → 1
Q4: Valid Parentheses
Description: Check if a string containing (), {}, [] is balanced (every open bracket has a corresponding close in the correct order).
Test Cases:
Â
- Input:Â “({[]})”
- Output:Â true
Â
- Input:Â “([)]”
- Output:Â false
Â
Edge Input:Â “”
Output:Â true
Q5: Two Sum in List of Key-Value Pairs
Description: Out of all key-value pairs, find any one pair of values whose sum is equal to a target value.
Â
Test Cases :
Â
- Input:Â pairs = [(1, 5), (2, 3), (3, 8), (4, 2)], target = 10
- Output:Â (5, 5) or (2, 8)
Â
Edge Input:Â pairs = [(7, 4)], target = 8
Output:Â No valid pair
Q6: Reverse Words in a String (In-Place)
Description: Given a string, reverse the letters in each word in place, using only constant extra space.
Â
Test Cases:
Â
- Input:Â “hello world”
- Output:Â “olleh dlrow”
Â
- Input:Â “a b c”
- Output:Â “a b c”
Â
- Edge Input:Â “”
- Output:Â “”
Q7: Rotten Oranges
Test Cases :
- Input:Â grid = [,,]
- Output:Â 4
- Input:Â grid = [,,]
- Output:Â -1
- Edge Input:Â grid = []
- Output:Â 0
Q8: Next Permutation
Description: Given an array, rearrange into the next lexicographically greater permutation. If none exists, return the lowest possible order.
Q9: Maximum Rectangle in a Histogram/Matrix
Description: Find area of the largest rectangle of 1’s in a binary histogram or matrix.
Test Cases:
Â
- Histogram Input:
- Output:Â 10
Â
Matrix Input:Â [,,,]
Output:Â 6
Q10: Maximum Sum of Non-Adjacent Elements
Q11: Longest Consecutive Subsequence in Array
Description: Given positive integers, find the longest subsequence where all numbers are consecutive.
Test Cases:
Â
- Input:
- Output:Â 4
Â
Input: 36, 41, 56, 35, 44, 33, 34, 92, 43,
Output:Â 5
Q12: Height of Binary Tree (Recursive & Iterative)
Description: Given a binary tree, return its height using both recursion and iteration.
Â
Test Cases:
Â
Input:Â Tree with nodes
-
Output:Â 3
-
Edge Input:Â null
-
Output:Â 0
-
Edge Input:Â Single node (7)
-
Output:Â 1
Q13: Stack using Queue
Description: Implement a stack using standard queue operations.
Â
Test Cases:
Â
- Input Sequence:Â push(1), push(2), top(), pop(), top()
- Output:Â 2, 2, 1
Q1. Spring Boot Project: REST API & Service Layer
Description: Add or extend APIs in a given Spring Boot codebase, designing the controller, service, and data layers. Implement pagination, error handling, and write unit/integration tests.
Q2. Machine Coding: Todo List (CRUD)
Description: Implement add, delete, mark-complete, and search for a todo list.
Q3. Student & Teacher OOP Classes
Description: Design base class (SchoolMember), and extend for Student and Teacher with common and unique properties. Implement methods like getTotalStrength(), getStudentInfo(), getTeacherSubjects().
Q4. Producer-Consumer with BlockingQueue (Java)
Description: Use Java concurrency to implement producer and consumer logic using a blocking queue.
Q5. Car Pooling Application (Spring Boot)
Description: End-to-end code for a ride-sharing platform, including user journeys, ride booking, and robust RESTful design.
Q1. CAP Theorem & ACID Properties Discussion
Description: Explain the CAP theorem, database isolation levels, and when to use systems that prioritize consistency, availability, or partition-tolerance.
Q2. Online Bidding System
Description: Architect a scalable, robust system for online bidding (auctions), handling thousands of concurrent users, efficient bid submission, and real-time winner updates.
Q3. E-commerce Platform
Description: End-to-end system design for modern e-commerce, covering catalog, orders, inventory, payments, user management, scaling, caching, resiliency.
Q4. API Robustness, Pagination, Scalability
Description: Design APIs to efficiently handle heavy loads, proper pagination, rate limiting, error handling, and handle thundering herd problem.
Q1. Machine Learning Basics and Vector Database
Description: General discussion on core ML principles — what is machine learning, when to use, K-means clustering, RAG (retrieval augmented generation), vector embeddings/DB, reinforcement learning, neural networks.