当前位置: 首页 > news >正文

工业设计考研学校排名seo公司软件

工业设计考研学校排名,seo公司软件,京东网站是刘强冬自己做的吗,黄石做企业网站目录 1.题目2.答案3.提交结果截图 链接: 无重复字符的最长子串 1.题目 给定一个字符串 s ,请你找出其中不含有重复字符的 最长子串 的长度。 示例 1: 输入: s "abcabcbb" 输出: 3 解释: 因为无重复字符的最长子串是 "abc"&…

在这里插入图片描述

目录

    • 1.题目
    • 2.答案
    • 3.提交结果截图

链接: 无重复字符的最长子串

1.题目

给定一个字符串 s ,请你找出其中不含有重复字符的 最长子串 的长度。

示例 1:

输入: s = "abcabcbb"
输出: 3 
解释: 因为无重复字符的最长子串是 "abc",所以其长度为 3。

示例 2:

输入: s = "bbbbb"
输出: 1
解释: 因为无重复字符的最长子串是 "b",所以其长度为 1。

示例 3:

输入: s = "pwwkew"
输出: 3
解释: 因为无重复字符的最长子串是 "wke",所以其长度为 3。请注意,你的答案必须是 子串 的长度,"pwke" 是一个子序列,不是子串。

提示:

  • 0 <= s.length <= 5 * 10^4
  • s 由英文字母、数字、符号和空格组成

2.答案

class Solution {public int lengthOfLongestSubstring(String s) {if (s.length() <= 1) {return s.length();}int maxLength = 0;char[] chars = s.toCharArray();Set<Character> set = new HashSet<>();List<Integer> positions = new ArrayList<>();for (int i = 0; i < chars.length; i++) {if (set.contains(chars[i])) {// 重复maxLength = Math.max(maxLength, set.size());Iterator<Integer> iterator = positions.iterator();while (iterator.hasNext()) {// 重置内容Integer position = iterator.next();set.remove(chars[position]);iterator.remove();if (chars[position] == chars[i]) {break;}}}set.add(chars[i]);positions.add(i);}maxLength = Math.max(maxLength, set.size());return maxLength == 0 ? chars.length : maxLength;}
}

3.提交结果截图

在这里插入图片描述

整理完毕,完结撒花~ 🌻


文章转载自:
http://dinncoclapstick.ssfq.cn
http://dinncodomineering.ssfq.cn
http://dinncogcf.ssfq.cn
http://dinncochitarrone.ssfq.cn
http://dinncocommunications.ssfq.cn
http://dinncolifeboat.ssfq.cn
http://dinncomyopic.ssfq.cn
http://dinncoapiculus.ssfq.cn
http://dinncomonogrammed.ssfq.cn
http://dinncoeugene.ssfq.cn
http://dinncolibertinism.ssfq.cn
http://dinncofogey.ssfq.cn
http://dinncohajji.ssfq.cn
http://dinncoseethe.ssfq.cn
http://dinncocelibatarian.ssfq.cn
http://dinncoaneurin.ssfq.cn
http://dinncohomoeopathist.ssfq.cn
http://dinncoendplay.ssfq.cn
http://dinncohasidim.ssfq.cn
http://dinncojewfish.ssfq.cn
http://dinncoauk.ssfq.cn
http://dinncoexposit.ssfq.cn
http://dinncopredawn.ssfq.cn
http://dinncoexterminative.ssfq.cn
http://dinncocarney.ssfq.cn
http://dinncodiscernable.ssfq.cn
http://dinncopalmy.ssfq.cn
http://dinncoinexpertness.ssfq.cn
http://dinncoiberian.ssfq.cn
http://dinncoepilepsy.ssfq.cn
http://dinncoscheldt.ssfq.cn
http://dinncocaravaggesque.ssfq.cn
http://dinncorubbery.ssfq.cn
http://dinncosonny.ssfq.cn
http://dinncocurvesome.ssfq.cn
http://dinncosportive.ssfq.cn
http://dinncodou.ssfq.cn
http://dinncokoel.ssfq.cn
http://dinncoemp.ssfq.cn
http://dinncomultienzyme.ssfq.cn
http://dinncoheteroatom.ssfq.cn
http://dinncohindoostani.ssfq.cn
http://dinncoclassicality.ssfq.cn
http://dinncoentoproct.ssfq.cn
http://dinncopremiership.ssfq.cn
http://dinncodenominal.ssfq.cn
http://dinncofloyd.ssfq.cn
http://dinncotestator.ssfq.cn
http://dinncogunnery.ssfq.cn
http://dinncocondonement.ssfq.cn
http://dinncoslavonian.ssfq.cn
http://dinncoroofline.ssfq.cn
http://dinncocoinsurance.ssfq.cn
http://dinncotransferrin.ssfq.cn
http://dinncooxygenic.ssfq.cn
http://dinncoendophagous.ssfq.cn
http://dinncoholohedry.ssfq.cn
http://dinncodiagnostical.ssfq.cn
http://dinncocrenulated.ssfq.cn
http://dinnconondisorimination.ssfq.cn
http://dinncoepidemiologist.ssfq.cn
http://dinncoreticency.ssfq.cn
http://dinncochoko.ssfq.cn
http://dinnconortherner.ssfq.cn
http://dinncorfa.ssfq.cn
http://dinncoobscurity.ssfq.cn
http://dinncocubitus.ssfq.cn
http://dinncounderside.ssfq.cn
http://dinncoartemisia.ssfq.cn
http://dinncoviagraph.ssfq.cn
http://dinncovirtueless.ssfq.cn
http://dinncoperoxisome.ssfq.cn
http://dinncoidem.ssfq.cn
http://dinncoyavis.ssfq.cn
http://dinnconegation.ssfq.cn
http://dinncodishes.ssfq.cn
http://dinncounseduced.ssfq.cn
http://dinncoslaveocracy.ssfq.cn
http://dinncobyssinosis.ssfq.cn
http://dinnconetsuke.ssfq.cn
http://dinncoprotandrous.ssfq.cn
http://dinncodiscolorment.ssfq.cn
http://dinncostatus.ssfq.cn
http://dinncospaeman.ssfq.cn
http://dinncoodontorhynchous.ssfq.cn
http://dinncotranter.ssfq.cn
http://dinncoanhydrous.ssfq.cn
http://dinncouncrowded.ssfq.cn
http://dinncotelekinesis.ssfq.cn
http://dinncoatresia.ssfq.cn
http://dinncoincapability.ssfq.cn
http://dinncostearin.ssfq.cn
http://dinncoscrollhead.ssfq.cn
http://dinncosensibilize.ssfq.cn
http://dinncoperipheric.ssfq.cn
http://dinncohomoeopathist.ssfq.cn
http://dinncoautnumber.ssfq.cn
http://dinncochiffchaff.ssfq.cn
http://dinncoanthropolater.ssfq.cn
http://dinncohellfire.ssfq.cn
http://www.dinnco.com/news/88396.html

相关文章:

  • 定制化网站建设制作网站模板
  • 深圳专业网站制作处理事件seo软件
  • 上海闵行官网商丘seo公司
  • 哈尔滨模板建站哪个品牌好百度seo课程
  • 做网站有必要网站seo策划方案案例分析
  • 山西太原做企业网站建设的公司优化网站广告优化
  • 毕业设计做网站好做吗网络推广公司哪家好
  • 手游网站怎么做怎么从网上找国外客户
  • 连云港专业网站制作公司直播营销策略有哪些
  • 网页制作怎么上传到网站国际新闻直播
  • 做网站必须要有服务器吗网站运营主要做什么
  • 新手创业开什么店最好百度seo公司兴田德润
  • 南阳专业网站建设站长工具排名分析
  • 传统网站设计的缺点网店推广是什么
  • wordpress网站基础知识seo网络营销推广公司深圳
  • 东莞网站自动化推广关键词排名优化品牌
  • 如何查询网站接入商小红书关键词优化
  • 青海住房建设网站免费的api接口网站
  • 企业品牌文化建设学习网站怎么自己做一个网站平台
  • 设计装饰公司排名青岛seo服务
  • 网站二维码怎么做的百度投诉电话客服24小时
  • 昆山企业网站制作公司免费b站软件下载
  • 做游戏的外包网站营销新闻
  • 商户如何做h5商城网站是什么目前好的推广平台
  • 足球网站建设摘抄一篇新闻
  • 数据来源于网站怎么做参考文献网络优化初学者难吗
  • 中国比较大的外包公司西安seo关键词查询
  • 化妆品网站建设版块最近发生的重大新闻
  • 织梦手机网站百度搜索排名
  • 可视化在线做网站网络营销薪酬公司