General Motors Interview Questions — 8 DSA Problems
6 problems with full solutions in Python, Java, C++, JavaScript, Go, Rust.
Most frequently asked General Motors LeetCode questions for software engineering interviews.
- Number of Connected Components in an Undirected Graph (MEDIUM) — Depth-First Search, Breadth-First Search, Union Find, Graph
- First Missing Positive (HARD) — Array, Hash Table
- Minimum Path Sum (MEDIUM) — Array, Dynamic Programming, Matrix
- LRU Cache (MEDIUM) — Hash Table, Linked List, Design, Doubly-Linked List
- The Number of Full Rounds You Have Played (MEDIUM) — Math, String
- Last Visited Integers (EASY) — Array, Simulation
- Widest Vertical Area Between Two Points Containing No Points (EASY) — Array, Sorting
- Dot Product of Two Sparse Vectors (MEDIUM) — Array, Hash Table, Two Pointers, Design
GM
General Motors
8 questions tracked6 with solutions
Frequency scoreSorted highest → lowest frequency✓ Our Solution = we have a detailed walkthrough
Showing 8 of 8 questions
1MediumNumber of Connected Components in an Undirected Graph
Depth-First SearchBreadth-First SearchUnion FindGraph
3ArrayDynamic ProgrammingMatrix
4Hash TableLinked ListDesignDoubly-Linked List
7EasyWidest Vertical Area Between Two Points Containing No Points✓ Our Solution ArraySorting
8MediumDot Product of Two Sparse Vectors
ArrayHash TableTwo PointersDesign