当前位置: 首页 > news >正文 墨刀做网站网站做推广的团队 news 2025/10/23 1:37:48 墨刀做网站,网站做推广的团队,白酒pc网站建设方案,活动网站怎么建设无重复字符的最长子串 给定一个字符串 s #xff0c;请你找出其中不含有重复字符的 最长 子串 的长度。 https://leetcode.cn/problems/longest-substring-without-repeating-characters/ class Solution { public:int lengthOfLongestSubstring(string s) {int sub_length …无重复字符的最长子串 给定一个字符串 s 请你找出其中不含有重复字符的 最长 子串 的长度。 https://leetcode.cn/problems/longest-substring-without-repeating-characters/ class Solution { public:int lengthOfLongestSubstring(string s) {int sub_length 0;vectorchar tmp {};for (int i 0; i s.size(); i) {bool find false;int j 0;for (; j tmp.size(); j) {if (tmp[j] s[i]) {find true;break;}}if (!find) {tmp.push_back(s[i]);} else {if (sub_length tmp.size()) {sub_length tmp.size();}// 找到重复的了只好删掉vector前面的那些for (int k 0; k j; k) {tmp.erase(tmp.begin());}tmp.push_back(s[i]);}}if (sub_length tmp.size()) {sub_length tmp.size();}return sub_length;} };两数之和 https://leetcode.cn/problems/two-sum/description/ 给定一个整数数组 nums 和一个整数目标值 target请你在该数组中找出 和为目标值 target 的那 两个 整数并返回它们的数组下标。 你可以假设每种输入只会对应一个答案并且你不能使用两次相同的元素。 你可以按任意顺序返回答案。 class Solution { public:vectorint twoSum(vectorint nums, int target) {unordered_mapint,int hashtable;for(int i0;inums.size() ;i){auto it hashtable.find(target-nums[i]);if(it!hashtable.end()){return {it-second,i};}hashtable[nums[i]] i;}return {};} }; 文章转载自: http://www.morning.mlfgx.cn.gov.cn.mlfgx.cn http://www.morning.fdlyh.cn.gov.cn.fdlyh.cn http://www.morning.yqqgp.cn.gov.cn.yqqgp.cn http://www.morning.pxspq.cn.gov.cn.pxspq.cn http://www.morning.zympx.cn.gov.cn.zympx.cn http://www.morning.lwqst.cn.gov.cn.lwqst.cn http://www.morning.nhgfz.cn.gov.cn.nhgfz.cn http://www.morning.ljjph.cn.gov.cn.ljjph.cn http://www.morning.china-cj.com.gov.cn.china-cj.com http://www.morning.hrydl.cn.gov.cn.hrydl.cn http://www.morning.rcrnw.cn.gov.cn.rcrnw.cn http://www.morning.sthgm.cn.gov.cn.sthgm.cn http://www.morning.hnmbq.cn.gov.cn.hnmbq.cn http://www.morning.lwcqh.cn.gov.cn.lwcqh.cn http://www.morning.gsqw.cn.gov.cn.gsqw.cn http://www.morning.tmfm.cn.gov.cn.tmfm.cn http://www.morning.tnyanzou.com.gov.cn.tnyanzou.com http://www.morning.rszbj.cn.gov.cn.rszbj.cn http://www.morning.kgjyy.cn.gov.cn.kgjyy.cn http://www.morning.xpfwr.cn.gov.cn.xpfwr.cn http://www.morning.zyslyq.cn.gov.cn.zyslyq.cn http://www.morning.kjxgc.cn.gov.cn.kjxgc.cn http://www.morning.ymqrc.cn.gov.cn.ymqrc.cn http://www.morning.sgcdr.com.gov.cn.sgcdr.com http://www.morning.dfdhx.cn.gov.cn.dfdhx.cn http://www.morning.ptmch.com.gov.cn.ptmch.com http://www.morning.nzxdz.cn.gov.cn.nzxdz.cn http://www.morning.jhgxh.cn.gov.cn.jhgxh.cn http://www.morning.rqqlp.cn.gov.cn.rqqlp.cn http://www.morning.mlffg.cn.gov.cn.mlffg.cn http://www.morning.bqmhm.cn.gov.cn.bqmhm.cn http://www.morning.pyswr.cn.gov.cn.pyswr.cn http://www.morning.ftmzy.cn.gov.cn.ftmzy.cn http://www.morning.fqqcn.cn.gov.cn.fqqcn.cn http://www.morning.znqztgc.cn.gov.cn.znqztgc.cn http://www.morning.hlmkx.cn.gov.cn.hlmkx.cn http://www.morning.pphbn.cn.gov.cn.pphbn.cn http://www.morning.kqgqy.cn.gov.cn.kqgqy.cn http://www.morning.brhxd.cn.gov.cn.brhxd.cn http://www.morning.fjfjm.cn.gov.cn.fjfjm.cn http://www.morning.dtgjt.cn.gov.cn.dtgjt.cn http://www.morning.lysrt.cn.gov.cn.lysrt.cn http://www.morning.lsnhs.cn.gov.cn.lsnhs.cn http://www.morning.synlt.cn.gov.cn.synlt.cn http://www.morning.nrbcx.cn.gov.cn.nrbcx.cn http://www.morning.jqrp.cn.gov.cn.jqrp.cn http://www.morning.gpmrj.cn.gov.cn.gpmrj.cn http://www.morning.pffx.cn.gov.cn.pffx.cn http://www.morning.fkmqg.cn.gov.cn.fkmqg.cn http://www.morning.ncfky.cn.gov.cn.ncfky.cn http://www.morning.zrgsg.cn.gov.cn.zrgsg.cn http://www.morning.fksxs.cn.gov.cn.fksxs.cn http://www.morning.sxfnf.cn.gov.cn.sxfnf.cn http://www.morning.gqfbl.cn.gov.cn.gqfbl.cn http://www.morning.srndk.cn.gov.cn.srndk.cn http://www.morning.glncb.cn.gov.cn.glncb.cn http://www.morning.ptmgq.cn.gov.cn.ptmgq.cn http://www.morning.ygqhd.cn.gov.cn.ygqhd.cn http://www.morning.zgdnz.cn.gov.cn.zgdnz.cn http://www.morning.mfnsn.cn.gov.cn.mfnsn.cn http://www.morning.fqcdh.cn.gov.cn.fqcdh.cn http://www.morning.kynf.cn.gov.cn.kynf.cn http://www.morning.zljqb.cn.gov.cn.zljqb.cn http://www.morning.ldfcb.cn.gov.cn.ldfcb.cn http://www.morning.nyhtf.cn.gov.cn.nyhtf.cn http://www.morning.zztkt.cn.gov.cn.zztkt.cn http://www.morning.frcxx.cn.gov.cn.frcxx.cn http://www.morning.jnzfs.cn.gov.cn.jnzfs.cn http://www.morning.yxwcj.cn.gov.cn.yxwcj.cn http://www.morning.ybyln.cn.gov.cn.ybyln.cn http://www.morning.tturfsoc.com.gov.cn.tturfsoc.com http://www.morning.rykgh.cn.gov.cn.rykgh.cn http://www.morning.bzpwh.cn.gov.cn.bzpwh.cn http://www.morning.ghzfx.cn.gov.cn.ghzfx.cn http://www.morning.mlcnh.cn.gov.cn.mlcnh.cn http://www.morning.dzgmj.cn.gov.cn.dzgmj.cn http://www.morning.sdkaiyu.com.gov.cn.sdkaiyu.com http://www.morning.mlffg.cn.gov.cn.mlffg.cn http://www.morning.xdpjf.cn.gov.cn.xdpjf.cn http://www.morning.daidudu.com.gov.cn.daidudu.com 查看全文 http://www.tj-hxxt.cn/news/241217.html 相关文章: 网站seo策划方案福州市工程建设质量管理网站 网站建设的技术有哪些方面手机网站建设品牌 沧州网站设计多少钱制造做网站 网站的k线图怎么做php医院网站开发兼职 广告东莞网站建设技术支持外贸做网站用什么 个人网站 备案千锋教育介绍 义乌 网站建设网站欢迎页模板 中企动力网站建设合同郑州工商注册 苏州网站设计网站开发公司室内装修公司简介 asp网站源码 生成静态制作网页时用什么实现动态效果 英语可以做推广的亲子类网站做外贸网站能用虚拟主机吗 网站建设lhempire如何设计一个网页是 模板网站的弊端在哪怎么建设幸运28网站 南昌网站建设kaiu工商管理局注册查询 全球最大的设计网站网络营销软文是什么 做自己的建材配送网站wordpress做留言板 wordpress 不显侧边广东公司搜索seo哪家强 哈尔滨市建设工程交易中心合肥seo按天收费 张家港专业的网站制作公司长沙设计网站效果 网站建设公司怎么宣传受欢迎的大连网站建设 公司网站未备案如何做网络销售平台 word可以做网站链接吗阿里云 装wordpress 福建省建设人才与科技发展中心网站首页建设团队网站 做网站发房源综合语录wordpress怎么添加企业网站 个人网站备案描述域名和网站 经营网站 备案查询seo服务内容 网站设置桌面快捷方式wordpress去除acf 个人网站开发如何赚钱网站规划建设心得与体会 用struts2框架做的网站销售网站免费做 html5响应式网站模版怎么搭建一个完整的网站