Skip to content

Interview Solver

FeaturesPricingHelp
Sign In
FeaturesPricingHelpSign In
Interview Questions›Topics›Rolling Hash

Rolling Hash Interview Questions

Master 23 rolling hash problems frequently asked in technical interviews. These questions test your understanding of rolling hashconcepts and are essential for coding interview success.

23
Total Problems
1
Easy
11
Medium
11
Hard

Related Topics

Hash FunctionStringString MatchingArrayZ AlgorithmBinary SearchSliding WindowSuffix Array
#1697MediumFrequency: 65.5%

Strings Differ by One Character

Asked at Airbnb
Hash TableStringRolling HashHash Function
#1
Rank
#187MediumFrequency: 57.5%

Repeated DNA Sequences

Asked at LinkedIn
Hash TableStringBit ManipulationSliding WindowRolling HashHash FunctionZ AlgorithmBoyer–Moore String-Search Algorithm
#2
Rank
#2339MediumFrequency: 47.5%

K Divisible Elements Subarrays

Asked at Uber
ArrayHash TableTrieRolling HashHash FunctionEnumeration
#3
Rank
#3333MediumFrequency: 47.5%

Find Pattern in Infinite Stream I

Asked at Uber
ArraySliding WindowRolling HashString MatchingInteractiveHash Function
#4
Rank
#3352HardFrequency: 47.5%

Find Pattern in Infinite Stream II

Asked at Uber
ArraySliding WindowRolling HashString MatchingInteractiveHash Function
#5
Rank
#214HardFrequency: 38.2%

Shortest Palindrome

Asked at Google
StringRolling HashString MatchingHash FunctionManacherZ AlgorithmKnuth–Morris–Pratt Algorithm
#6
Rank
#1122HardFrequency: 33%

Longest Duplicate Substring

Asked at TikTok
StringBinary SearchSliding WindowRolling HashSuffix ArrayHash FunctionSuffix AutomatonSuffix TreeZ AlgorithmBoyer–Moore String-Search Algorithm
#7
Rank
#3269MediumFrequency: 27.8%

Number of Subarrays That Match a Pattern I

Asked at Uber
ArrayRolling HashString MatchingHash Function
#8
Rank
#1060MediumFrequency: 23.6%

Longest Repeating Substring

Asked at Amazon
StringBinary SearchDynamic ProgrammingRolling HashSuffix ArrayHash FunctionSuffix AutomatonSuffix Tree
#9
Rank
#2051HardFrequency: 23.6%

Longest Common Subpath

Asked at Amazon
ArrayBinary SearchRolling HashSuffix ArrayHash FunctionSuffix AutomatonSuffix Tree
#10
Rank
#1557MediumFrequency: 23.3%

Check If a String Contains All Binary Codes of Size K

Asked at Google
Hash TableStringBit ManipulationRolling HashHash FunctionDirected Acyclic Graph
#11
Rank
#1508HardFrequency: 22%

Longest Happy Prefix

Asked at Apple
StringRolling HashString MatchingHash FunctionZ AlgorithmKnuth–Morris–Pratt Algorithm
#12
Rank
#3305HardFrequency: 20.3%

Count Prefix and Suffix Pairs II

Asked at Uber
ArrayStringTrieRolling HashString MatchingHash FunctionZ Algorithm
#13
Rank
#1838MediumFrequency: 20.3%

Number of Distinct Substrings in a String

Asked at Uber
StringTrieRolling HashSuffix ArrayHash Function
#14
Rank
#2326HardFrequency: 20%

Sum of Scores of Built Strings

Asked at Amazon
StringBinary SearchRolling HashSuffix ArrayString MatchingHash FunctionZ AlgorithmKnuth–Morris–Pratt Algorithm
#15
Rank
#3303HardFrequency: 19.5%

Find Beautiful Indices in the Given Array II

Asked at Google
Two PointersStringBinary SearchRolling HashString MatchingHash FunctionZ AlgorithmKnuth–Morris–Pratt AlgorithmBoyer–Moore String-Search Algorithm
#16
Rank
#3821MediumFrequency: 19.5%

Count Cells in Overlapping Horizontal and Vertical Substrings

Asked at Google
ArrayStringRolling HashString MatchingMatrixHash Function
#17
Rank
#1244HardFrequency: 18%

Distinct Echo Substrings

Asked at Google
StringTrieRolling HashSuffix ArrayHash FunctionSuffix AutomatonSuffix Tree
#18
Rank
#1251HardFrequency: 18%

Longest Chunked Palindrome Decomposition

Asked at Google
Two PointersStringDynamic ProgrammingGreedyRolling HashHash Function
#19
Rank
#718MediumFrequency: 18%

Maximum Length of Repeated Subarray

Asked at Google
ArrayBinary SearchDynamic ProgrammingSliding WindowRolling HashHash Function
#20
Rank
#3245MediumFrequency: 7.3%

Find Beautiful Indices in the Given Array I

Asked at Microsoft
Two PointersStringBinary SearchRolling HashString MatchingHash FunctionZ AlgorithmKnuth–Morris–Pratt AlgorithmBoyer–Moore String-Search Algorithm
#21
Rank
#3309EasyFrequency: 5%

Count Prefix and Suffix Pairs I

Asked at Google
ArrayStringTrieRolling HashString MatchingHash Function
#22
Rank
#2275HardFrequency: 5%

Find Substring With Given Hash Value

Asked at Google
StringSliding WindowRolling HashHash Function
#23
Rank
View All Topics

Master Rolling Hash in Real Interviews

Get AI-powered assistance when solving rolling hash problems during your actual interviews.

Get Started Free

No credit card required

Interview Solver
  • Home
  • About
  • Pricing
  • Sign in
  • Contact
  • Blog
  • Companion
  • Help Center
  • Developers
  • Use Cases
  • Software Engineer
  • Product Manager
  • Misc
  • Privacy Policy
  • Terms and Conditions
  • Refund & Cancellation
  • Discord Community
  • Affiliate Program
  • Compare
  • All Comparisons
  • vs Final Round AI
  • vs UltraCode
  • vs Interview Coder
  • vs LockedIn AI
  • vs AI Apply
  • Free Tools
  • ATS Resume Checker
  • STAR Method Builder
  • Salary Lookup
  • Big O Cheat Sheet
  • Total Comp Calculator
  • View All →
  • Interview Questions
  • Google Questions
  • Amazon Questions
  • Microsoft Questions
  • Meta Questions
  • Apple Questions
  • TikTok Questions
  • View All →
© 2026 Interview Solver, Inc. All rights reserved.