MediumSliding Window· 58% acceptance
#555

Longest Substring Without Repeating 10

Medium

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

Example 1

Input: s = "efabcdef"

Output: 6

Constraints

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

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

lengthOfLongestSubstring

← All practice problems