0% found this document useful (0 votes)
12 views

0005 Leetcode 3. Longest Substring Without Repeating Characters

Leetcode answer

Uploaded by

trieukhac99
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
12 views

0005 Leetcode 3. Longest Substring Without Repeating Characters

Leetcode answer

Uploaded by

trieukhac99
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 3

Leetcode 3. Longest Substring Without Repeating Characters https://leetcode.ca/all/3.

html

Leetcode Solutions Java Python C++ (https://leetcode.ca)


All contents and pictures on this website come from the Internet and are updated regularly
every week. They are for personal study and research only, and should not be used for
commercial purposes. Thank you for your cooperation.

Welcome to Subscribe On Youtube:

3. Longest Substring Without


Repeating Characters
Given a string, find the length of the longest substring without
repeating characters.

Example 1:

Input: "abcabcbb"
Output: 3
Explanation: The answer is "abc", with the length of 3.

Example 2:

Input: "bbbbb"
Output: 1
Explanation: The answer is "b", with the length of 1.

Example 3:

Input: "pwwkew"
Output: 3
Explanation: The answer is "wke", with the length of 3.
Note that the answer must be a substring, "pwke" is a

Difficulty:
Medium

Lock:

1 of 3 21/11/2024, 10:59 pm
Leetcode 3. Longest Substring Without Repeating Characters https://leetcode.ca/all/3.html

Normal

Company:
Adobe (https://leetcode.ca/tags/#Adobe)
Alation (https://leetcode.ca/tags/#Alation)
Alibaba (https://leetcode.ca/tags/#Alibaba)

Amazon (https://leetcode.ca/tags/#Amazon)
Apple (https://leetcode.ca/tags/#Apple)
Atlassian (https://leetcode.ca/tags/#Atlassian)

Baidu (https://leetcode.ca/tags/#Baidu)
Bloomberg (https://leetcode.ca/tags/#Bloomberg)

ByteDance (https://leetcode.ca/tags/#ByteDance)

Cisco (https://leetcode.ca/tags/#Cisco) eBay (https://leetcode.ca/tags/#eBay)


Expedia (https://leetcode.ca/tags/#Expedia)

Facebook (https://leetcode.ca/tags/#Facebook)

Goldman Sachs (https://leetcode.ca/tags/#Goldman Sachs)


Google (https://leetcode.ca/tags/#Google)

Huawei (https://leetcode.ca/tags/#Huawei)
Microsoft (https://leetcode.ca/tags/#Microsoft)

Oracle (https://leetcode.ca/tags/#Oracle) Paypal (https://leetcode.ca/tags/#Paypal)

Salesforce (https://leetcode.ca/tags/#Salesforce)
Samsung (https://leetcode.ca/tags/#Samsung)

SAP (https://leetcode.ca/tags/#SAP)
Snapchat (https://leetcode.ca/tags/#Snapchat)

Tencent (https://leetcode.ca/tags/#Tencent)

Twitch (https://leetcode.ca/tags/#Twitch) Uber (https://leetcode.ca/tags/#Uber)


VMware (https://leetcode.ca/tags/#VMware)

Walmart Labs (https://leetcode.ca/tags/#Walmart Labs)


Yahoo (https://leetcode.ca/tags/#Yahoo)

Yandex (https://leetcode.ca/tags/#Yandex) Yelp (https://leetcode.ca/tags/#Yelp)

Zillow (https://leetcode.ca/tags/#Zillow) Zoho (https://leetcode.ca/tags/#Zoho)

Problem Solution

3-Longest-Substring-Without-Repeating-Characters
(https://leetcode.ca/2015-12-03-3-Longest-Substring-
Without-Repeating-Characters)

2 of 3 21/11/2024, 10:59 pm
Leetcode 3. Longest Substring Without Repeating Characters https://leetcode.ca/all/3.html

All Problems:

Link to All Problems (https://leetcode.ca/all/


problems.html)
All contents and pictures on this website come from the
Internet and are updated regularly every week. They are for
personal study and research only, and should not be used for
commercial purposes. Thank you for your cooperation.

3 of 3 21/11/2024, 10:59 pm

You might also like