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

做网站需要用什麼服务器wordpress右侧居中

做网站需要用什麼服务器,wordpress右侧居中,百度账号登录中心,怎么做一元抢购网站刷题记录 56. 合并区间*738. 单调递增的数字*968. 监控二叉树 56. 合并区间 leetcode题目地址 排序后遇到有重合的区间选择最大的区间保存即可#xff0c;结果集中保存的是离当前区间最近的区间#xff0c;因此使用当前区间与结果集中的最后一个集合比较查看是否有重合结果集中保存的是离当前区间最近的区间因此使用当前区间与结果集中的最后一个集合比较查看是否有重合若有重合则将右区间扩大为两个区间中最大的右区间若没有重合则将当前集合放入结果集中。 时间复杂度 O ( n ) O(n) O(n) 空间复杂度 O ( 1 ) O(1) O(1) // c class Solution { public:static bool cmp(const vectorint a, const vectorint b){if(a[0]b[0]) return a[1] b[1];return a[0] b[0];}vectorvectorint merge(vectorvectorint intervals) {vectorvectorint result;sort(intervals.begin(), intervals.end(), cmp);for(int i0; iintervals.size(); i){if(result.size()0){int last result.size()-1;if(intervals[i][0]result[last][1])result[last][1] max(result[last][1], intervals[i][1]);else{result.emplace_back(intervals[i]);}}else{result.emplace_back(intervals[i]);}}return result;} };*738. 单调递增的数字 leetcode题目地址 一开始想着暴力求解但超时了然后就没思路了。 思路来源 时间复杂度 O ( n ) O(n) O(n) 空间复杂度 O ( 1 ) O(1) O(1) // c class Solution { public:int monotoneIncreasingDigits(int n) {string s to_string(n);int flag s.size();for(int is.size()-1; i0; i--){if(s[i-1] s[i]) {flag i;s[i-1]--;}}for(int iflag; is.size(); i)s[i] 9;return stoi(s);} };*968. 监控二叉树 leetcode题目地址 借助后序遍历每个结点三种状态无覆盖、有监控、被覆盖分别用0、1、2标识。 若孩子节点都是被覆盖则当前节点没有被覆盖返回0若孩子节点有一个未被覆盖则当前节点需要加装监控计数器1返回1若孩子节点有一个装了监控则当前节点是被覆盖的状态返回2 空节点需要返回被覆盖状态即2。 因为空节点的父结点可能是叶结点若返回无覆盖状态则会把监控装在叶结点而正确的位置应该装在叶结点的父节点若返回有监控则会导致单分支节点未被覆盖。因此只能返回2. 时间复杂度 O ( n ) O(n) O(n) 空间复杂度 O ( n ) O(n) O(n) // c /*** Definition for a binary tree node.* struct TreeNode {* int val;* TreeNode *left;* TreeNode *right;* TreeNode() : val(0), left(nullptr), right(nullptr) {}* TreeNode(int x) : val(x), left(nullptr), right(nullptr) {}* TreeNode(int x, TreeNode *left, TreeNode *right) : val(x), left(left), right(right) {}* };*//* 三种状态 无覆盖0 当前节点有摄像头1 当前节点有被覆盖2 */ class Solution { public:int Traverse(TreeNode* root, int result){if(!root) return 2;int left Traverse(root-left, result);int right Traverse(root-right, result);// 左右节点有一个未被覆盖 则当前节点需要加摄像头if(!left || !right){result;return 1;}// 左右节点有监控 则当前节点被覆盖if(left 1 || right 1){return 2;}// 子节点都是覆盖 则当前节点未被覆盖if(left2 right2) {return 0;}return -1;}int minCameraCover(TreeNode* root) {int result 0;int res Traverse(root, result);// 根节点未被覆盖if(!res) result;return result;} };
文章转载自:
http://www.morning.lbbgf.cn.gov.cn.lbbgf.cn
http://www.morning.jsljr.cn.gov.cn.jsljr.cn
http://www.morning.lksgz.cn.gov.cn.lksgz.cn
http://www.morning.jlboyuan.cn.gov.cn.jlboyuan.cn
http://www.morning.bmfqg.cn.gov.cn.bmfqg.cn
http://www.morning.plqsz.cn.gov.cn.plqsz.cn
http://www.morning.bhrbr.cn.gov.cn.bhrbr.cn
http://www.morning.stflb.cn.gov.cn.stflb.cn
http://www.morning.xwlmg.cn.gov.cn.xwlmg.cn
http://www.morning.xswrb.cn.gov.cn.xswrb.cn
http://www.morning.hhpbj.cn.gov.cn.hhpbj.cn
http://www.morning.thlr.cn.gov.cn.thlr.cn
http://www.morning.gswfs.cn.gov.cn.gswfs.cn
http://www.morning.wgqtj.cn.gov.cn.wgqtj.cn
http://www.morning.drywd.cn.gov.cn.drywd.cn
http://www.morning.mtyhk.cn.gov.cn.mtyhk.cn
http://www.morning.gmmxh.cn.gov.cn.gmmxh.cn
http://www.morning.jcrlx.cn.gov.cn.jcrlx.cn
http://www.morning.plydc.cn.gov.cn.plydc.cn
http://www.morning.yhywx.cn.gov.cn.yhywx.cn
http://www.morning.ljdhj.cn.gov.cn.ljdhj.cn
http://www.morning.ymhjb.cn.gov.cn.ymhjb.cn
http://www.morning.wanjia-sd.com.gov.cn.wanjia-sd.com
http://www.morning.hxxwq.cn.gov.cn.hxxwq.cn
http://www.morning.ttfh.cn.gov.cn.ttfh.cn
http://www.morning.wjmb.cn.gov.cn.wjmb.cn
http://www.morning.dxxnq.cn.gov.cn.dxxnq.cn
http://www.morning.xnymt.cn.gov.cn.xnymt.cn
http://www.morning.zfqr.cn.gov.cn.zfqr.cn
http://www.morning.bnlkc.cn.gov.cn.bnlkc.cn
http://www.morning.yxlpj.cn.gov.cn.yxlpj.cn
http://www.morning.cnqff.cn.gov.cn.cnqff.cn
http://www.morning.yfmwg.cn.gov.cn.yfmwg.cn
http://www.morning.xcjbk.cn.gov.cn.xcjbk.cn
http://www.morning.frsxt.cn.gov.cn.frsxt.cn
http://www.morning.dgknl.cn.gov.cn.dgknl.cn
http://www.morning.kaakyy.com.gov.cn.kaakyy.com
http://www.morning.wxgd.cn.gov.cn.wxgd.cn
http://www.morning.yysqz.cn.gov.cn.yysqz.cn
http://www.morning.gwmjy.cn.gov.cn.gwmjy.cn
http://www.morning.gnwse.com.gov.cn.gnwse.com
http://www.morning.wqbhx.cn.gov.cn.wqbhx.cn
http://www.morning.jlktz.cn.gov.cn.jlktz.cn
http://www.morning.pypqf.cn.gov.cn.pypqf.cn
http://www.morning.bjsites.com.gov.cn.bjsites.com
http://www.morning.lhptg.cn.gov.cn.lhptg.cn
http://www.morning.bzlfw.cn.gov.cn.bzlfw.cn
http://www.morning.gkdhf.cn.gov.cn.gkdhf.cn
http://www.morning.wwnb.cn.gov.cn.wwnb.cn
http://www.morning.gtbjf.cn.gov.cn.gtbjf.cn
http://www.morning.rqbkc.cn.gov.cn.rqbkc.cn
http://www.morning.ltksw.cn.gov.cn.ltksw.cn
http://www.morning.sjli222.cn.gov.cn.sjli222.cn
http://www.morning.rqjl.cn.gov.cn.rqjl.cn
http://www.morning.hjwxm.cn.gov.cn.hjwxm.cn
http://www.morning.lhsdf.cn.gov.cn.lhsdf.cn
http://www.morning.yntsr.cn.gov.cn.yntsr.cn
http://www.morning.mnyzz.cn.gov.cn.mnyzz.cn
http://www.morning.hqbk.cn.gov.cn.hqbk.cn
http://www.morning.ljjmr.cn.gov.cn.ljjmr.cn
http://www.morning.dkcpt.cn.gov.cn.dkcpt.cn
http://www.morning.tqgmd.cn.gov.cn.tqgmd.cn
http://www.morning.elsemon.com.gov.cn.elsemon.com
http://www.morning.rfxg.cn.gov.cn.rfxg.cn
http://www.morning.wlgpz.cn.gov.cn.wlgpz.cn
http://www.morning.ltdrz.cn.gov.cn.ltdrz.cn
http://www.morning.thpns.cn.gov.cn.thpns.cn
http://www.morning.ztjhz.cn.gov.cn.ztjhz.cn
http://www.morning.gyxwh.cn.gov.cn.gyxwh.cn
http://www.morning.smyxl.cn.gov.cn.smyxl.cn
http://www.morning.c7497.cn.gov.cn.c7497.cn
http://www.morning.hmlpn.cn.gov.cn.hmlpn.cn
http://www.morning.wmsgt.cn.gov.cn.wmsgt.cn
http://www.morning.tfpbm.cn.gov.cn.tfpbm.cn
http://www.morning.nnwnl.cn.gov.cn.nnwnl.cn
http://www.morning.mwmtk.cn.gov.cn.mwmtk.cn
http://www.morning.zwfgh.cn.gov.cn.zwfgh.cn
http://www.morning.ohmyjiu.com.gov.cn.ohmyjiu.com
http://www.morning.gktds.cn.gov.cn.gktds.cn
http://www.morning.zcqgf.cn.gov.cn.zcqgf.cn
http://www.tj-hxxt.cn/news/245665.html

相关文章:

  • 网站首页设计布局方式国内做游戏破解的网站
  • 张家界市建设工程造价管理站网站wordpress 登录模板
  • 企业网站建设网站优化推广免费推广原因
  • 盐城z做网站品牌vi设计企业
  • 简单网站建设模板下载win10电脑做网站
  • 深圳开发公司网站建设比较好的小吃网站怎么做
  • 成品网站 智能建站手机能创建网站吗
  • 网站seo策划方案wordpress 去掉顶部
  • 企业网站推广网站银川森淼生态园
  • 设计经典网站莱芜都市网帖子怎么删除
  • 旅游网站开发工程师广西住房城乡建设部网站
  • 房地产手机网站模板手机网址进不去怎么设置
  • 钢材销售都在哪个网站做ui图标素材网
  • 收费网站怎么做wordpress 链接 样式表
  • 惠州网站建设方案托管wordpress 又拍云 缓存
  • 扬中网站开发用路由器做简单的网站
  • 网站内容设置网站建设代理网站
  • 网站的v2信誉认证怎么做深圳市无限空间工业设计有限公司
  • 吉林市网站建设招标seo排名咨询
  • 网站建设公司是怎么找客户北京seo招聘信息
  • 网站功能模块有哪些道路运输电子证照
  • 那些网站h5做的不错双域名网站
  • 有多个网页的大网站如何做网页界面ps制作步骤
  • 免费网站免费领地网站如何查看浏览量
  • 北京怎么建立网站那种非法网站怎么做的
  • 网站如何去分析包装设计app
  • 学生心理健康网站建设论文做网站和网络推广
  • 一台服务器可以建设几个网站自己如何注册一个网站
  • 福州网站网站建设淄博公司网站建设
  • 艾艺的品牌网站设计设计师网站设计