Leetcode 3. Longest Substring Without Repeating Characters
Find the length of the longest contiguous substring that contains no repeated characters. This is a classic sliding-window / two-pointer problem where you track seen characters to expand and contract the window efficiently (linear-time expected).
Asked at:
Meta
Amazon
Expedia
Question Timeline
See when this question was last asked and where, including any notes left by other candidates.
Mid December, 2025
Expedia
Mid-level
modified version of *LeetCode 3 Given a string s, find the length of the longest substring that contains no repeated **letters**, treating uppercase and lowercase versions of the same letter as identical. All characters are allowed in the substring, including digits, symbols, and punctuation. However, only alphabetic characters (A–Z, a–z) participate in the “no-repeat” restriction. Non-alphabet characters do not affect uniqueness rules, but they still count toward the substring length.
Early October, 2025
Amazon
Mid-level
Mid February, 2025
Meta
Mid-level
Comments
Hello Interview Premium
Your account is free and you can post anonymously if you choose.