Google String Coding Interview Questions
219 string coding problems are tagged as asked at Google in interviews and online assessments reported by candidates. By difficulty they split into 76 basic, 103 intermediate and 40 advanced. The topics they most often combine with are Math, Hash Table, Stack, Two Pointers.
Reported questions change over time and are not a guarantee of what you will be asked, so use the list to see which patterns Google tends to test. For each problem, practise explaining your approach, its time and space cost and the edge cases before you write the code; every problem opens in an editor that runs your code against test cases.
Coding problems
- Valid Parentheses (Basic)
- Longest Substring Without Repeats (Intermediate)
- Reverse String (Basic)
- First Unique Character (Basic)
- Valid Palindrome (Basic)
- Decode Ways (Intermediate)
- Longest Palindromic Substring (Intermediate)
- Valid Anagram (Basic)
- Ransom Note (Basic)
- Repeated Substring Pattern (Intermediate)
- Reverse Words in a String (Basic)
- Reverse Vowels of a String (Basic)
- Roman to Integer (Intermediate)
- Excel Column Number (Basic)
- Add Binary (Basic)
- Length of Last Word (Basic)
- Longest Common Subsequence (Advanced)
- Edit Distance (Advanced)
- Longest Valid Parentheses (Advanced)
- Score of Parentheses (Intermediate)
- Greatest Common Divisor of Strings (Intermediate)
- Partition Labels (Intermediate)
- Sort Characters by Frequency (Intermediate)
- Remove Outer Parentheses (Basic)
- Shortest Distance to a Character (Intermediate)
- Maximum Number of Balloons (Basic)
- Remove Invalid Parentheses (Intermediate)
- Valid Parenthesis With Wildcards (Advanced)
- Is Subsequence (Basic)
- Minimum Deletions for Unique Frequencies (Intermediate)
- Permutation Inside a String (Intermediate)
- Zigzag Conversion (Intermediate)
- Remove K Digits to Get the Smallest Number (Intermediate)
- Compare Version Numbers (Intermediate)
- Count Palindromic Substrings (Intermediate)
- Longest Substring With At Most K Letters (Intermediate)
- Longest Palindromic Subsequence (Intermediate)
- Isomorphic Strings (Basic)
- Minimum Window Substring (Advanced)
- Shortest Palindrome (Advanced)
- Rotate String (Basic)
- Length of Last Word (Basic)
- Add Strings (Basic)
- Reconstruct Itinerary (Advanced)
- Text Justification (Intermediate)
- Palindrome Linked List (Basic)
- Zigzag Level Order Traversal (Intermediate)
- Level Order Traversal (Basic)
- Smallest String Starting From Leaf (Intermediate)
- Find Leaves of Binary Tree (Intermediate)
- Open the Lock (Intermediate)
- Minimum Genetic Mutation (Intermediate)
- Satisfiability of Equality Equations (Intermediate)
- Smallest String With Swaps (Intermediate)
- Regions Cut by Slashes (Intermediate)
- Similar String Groups (Advanced)
- Alien Dictionary Order (Advanced)
- Largest Color Value in a Directed Graph (Advanced)
- Interleaving String (Intermediate)
- Regular Expression Matching (Advanced)
- Ones and Zeroes (Intermediate)
- Scramble String (Advanced)
- Longest String Chain (Intermediate)
- Freedom Trail (Advanced)
- Strange Printer (Advanced)
- Maximum Students Taking Exam (Advanced)
- Two Keys Keyboard (Intermediate)
- Count Sorted Vowel Strings (Basic)
- Count Ways to Build Good Strings (Intermediate)
- Extra Characters in a String (Intermediate)
- Find First Occurrence (Basic)
- Longest Happy Prefix (Intermediate)
- Repeated String Match (Intermediate)
- Longest Duplicate Substring (Advanced)
- Distinct Echo Substrings (Advanced)
- String Compression (Basic)
- Valid Number (Advanced)
- String to Integer (Intermediate)
- Multiply Strings (Intermediate)
- Integer to English Words (Advanced)
Related
- Google coding interview questions
- String problems
- Google basic problems
- Google intermediate problems
- Google advanced problems
- Company interview roadmaps
- All interview guides
Frequently asked questions
How should I use the Google problem list?
Start with the basic problems, then the intermediate and advanced ones, and note which topics repeat. Solve each under a timer, then read the explanation.
Are these the exact Google interview questions?
They are problems candidates reported being asked. Companies rotate questions, so use them to learn the patterns, not to predict the exact question.