原文:LeetCode——3. Longest Substring Without Repeating Characters

一.題目鏈接:https: leetcode.com problems longest substring without repeating characters 二.題目大意: 給定一個字符串,返回它最長的無重復的子串的長度。 三.題解 該題目,我用了三種方法: .思路一:暴力解決,直接用兩層for循環對目標字符串所有的子串進行判斷。代碼如下: class Solution public: i ...

2017-11-27 12:59 0 1996 推薦指數:

查看詳情

 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM