MediumSliding Window· 59% acceptance
#556

Longest Substring Without Repeating 11

Medium

Return the length of the longest substring without repeating characters. Variant **#11**.

Example 1

Input: s = "fabcdefab"

Output: 6

Constraints

  • 0 <= s.length <= 5 * 10^4

Acceptance: 59% · Topics: sliding-window, hash-table, string

lengthOfLongestSubstring

← All practice problems