← Walmart questions
CodingMedium-HardReported in a candidate post, Aug 2021

Smallest Common Substring Pairs

Filed under Walmart

Given two strings A and B, find the number of pairs of substrings (one from A, one from B) that are identical and have the minimum possible length among all common substrings.

You've read your 3 free write-ups

Sign up free to keep reading. Your account opens the first 10 questions of every company.

Related Walmart questions

Collected from public candidate posts and coding forums. Updated Nov 2026.