E-COM-NET
首页
在线工具
Layui镜像站
SUI文档
联系我们
推荐频道
Java
PHP
C++
C
C#
Python
Ruby
go语言
Scala
Servlet
Vue
MySQL
NoSQL
Redis
CSS
Oracle
SQL Server
DB2
HBase
Http
HTML5
Spring
Ajax
Jquery
JavaScript
Json
XML
NodeJs
mybatis
Hibernate
算法
设计模式
shell
数据结构
大数据
JS
消息中间件
正则表达式
Tomcat
SQL
Nginx
Shiro
Maven
Linux
1023
计算机网络端口的定义
A、按端口号分布划分(1)知名端口(Well-KnownPorts)知名端口即众所周知的端口号,范围从0到
1023
,这些端口号一般固定分配给一些服务。比如21端口分配给FTP服务,25端口分配给S
siaisjack
·
2020-09-17 11:58
windows技巧
linux环境
【codechef】n个数,多少种取法的异或值==m【二项式定理】
第一发超时,原因是n=10^5,所以复杂度1024000,但是又想到所有数字都不超过
1023
,所以直接求每个数出现的次数就好。。但是——这样转化之后,考虑细心的地方就超多了!
ccyy-
·
2020-09-17 11:23
什么是“端口”?计算机端口?
按端口号可分为3大类:(1)公认端口(WellKnownPorts):从0到
1023
,它们紧密绑定(binding)于一些服务。通常这
迷惘,赚钱养梦
·
2020-09-17 10:30
网络
网络
docker 最大container数量调研
1、本地笔记本测试docker同时启动500个容器首先测试dockerdaemon支持的最大docker容器数量,查询文档发现,最大容器数量大概是
1023
个左右,在自己笔记本测试,启动500个容器,需要四分钟
vito0319
·
2020-09-17 05:01
docker
二级指针的作用详解
欢迎转载,转载请注明原文地址:http://blog.csdn.net/majianfei
1023
/article/details/46629065一、概念在如下的A指向B、B指向C的指向关系中:首先C
Lucky0928
·
2020-09-17 04:42
c
PAT刷题日记 B
1023
组个最小数
B
1023
组个最小数题目描述输入描述输出描述输入例子输出例子思路代码题目描述给定数字0-9各若干个。你可以以任意顺序排列这些数字,但必须全部使用。目标是使得最后得到的数尽可能小(注意0不能做首位)。
Bluenosezzz
·
2020-09-17 02:50
编程
算法
数据结构
贪心算法
PAT乙级
1023
组个最小数 (20分)
给定数字0-9各若干个。你可以以任意顺序排列这些数字,但必须全部使用。目标是使得最后得到的数尽可能小(注意0不能做首位)。例如:给定两个0,两个1,三个5,一个8,我们得到的最小的数就是10015558。现给定数字,请编写程序输出能够组成的最小的数。输入格式:输入在一行中给出10个非负整数,顺序表示我们拥有数字0、数字1、……数字9的个数。整数间用一个空格分隔。10个数字的总个数不超过50,且至少
Fmm-PMO
·
2020-09-17 02:23
PAT乙级
Linux的常用服务端口号
Linux端口的使用的规范端口号0不使用;端口号1-
1023
,系统默认只给root使用;端口号1024-4999由客户端程序自由分配;端口号5000-65535由服务器端程序自由分配;查询在/etc/services
蜡笔小新的心
·
2020-09-17 01:42
Linux
PTA-
1023
组个最小数
给定数字0-9各若干个。你可以以任意顺序排列这些数字,但必须全部使用。目标是使得最后得到的数尽可能小(注意0不能做首位)。例如:给定两个0,两个1,三个5,一个8,我们得到的最小的数就是10015558。现给定数字,请编写程序输出能够组成的最小的数。输入格式:输入在一行中给出10个非负整数,顺序表示我们拥有数字0、数字1、……数字9的个数。整数间用一个空格分隔。10个数字的总个数不超过50,且至少
Sun-wz
·
2020-09-17 01:14
PTA-B
1023
组个最小数 (20 分)
给定数字0-9各若干个。你可以以任意顺序排列这些数字,但必须全部使用。目标是使得最后得到的数尽可能小(注意0不能做首位)。例如:给定两个0,两个1,三个5,一个8,我们得到的最小的数就是10015558。现给定数字,请编写程序输出能够组成的最小的数。输入格式:输入在一行中给出10个非负整数,顺序表示我们拥有数字0、数字1、……数字9的个数。整数间用一个空格分隔。10个数字的总个数不超过50,且至少
Linuxsen
·
2020-09-17 01:21
PAT
乙级题解
PAT
乙级
1023
组个最小数 (20分)
给定数字0-9各若干个。你可以以任意顺序排列这些数字,但必须全部使用。目标是使得最后得到的数尽可能小(注意0不能做首位)。例如:给定两个0,两个1,三个5,一个8,我们得到的最小的数就是10015558。现给定数字,请编写程序输出能够组成的最小的数。输入格式:输入在一行中给出10个非负整数,顺序表示我们拥有数字0、数字1、……数字9的个数。整数间用一个空格分隔。10个数字的总个数不超过50,且至少
Hw&zdt
·
2020-09-17 00:24
pat乙级
VS2005上一个坑:关于pch 的 error C
1023
昨天编译就报错:c1xx:fatalerrorC
1023
:‘UnicodeDebug\ImEngine.pch’:unexpectederrorwithpch,tryrebuildingthepch——
weixin_30522183
·
2020-09-16 09:44
c/c++
PAT B
1023
-算法笔记顺序P121
1023
组个最小数(20分)给定数字0-9各若干个。你可以以任意顺序排列这些数字,但必须全部使用。目标是使得最后得到的数尽可能小(注意0不能做首位)。
warmeyes
·
2020-09-16 07:15
C++
PAT
Arduino - 摇杆模块
VRx,VRy的值:从0~
1023
分别代表左~右,上~下。中间值为512。SW(Z轴)是数字输入信号,连接到数字端口,并启用上拉电阻。SW的值:1代表未按下,0代表按下。
卢光庆
·
2020-09-15 09:41
Arduino
backup error 自动备份错误
exportingtableSALES_STATISTICEXP-00056:ORACLEerror3113encounteredORA-03113:end-of-fileoncommunicationchannelEXP-00008:ORACLEerror
1023
encounteredORA
曾小可
·
2020-09-15 07:03
backup
推荐几个树莓派 raspbian 系统 可用的 arm docker源
versionLinuxversion4.9.41-v7+(dc4@dc4-XPS13-9333)(gccversion4.9.3(crosstool-NGcrosstool-ng-1.22.0-88-g8460611))#
1023
SMPTueAug816
weixin_30492601
·
2020-09-15 03:47
运维
嵌入式
网络
《汇编语言》 清华大学 第二版 课后检测点 答案
《汇编语言》清华大学第二版课后检测点检测点1.1(第8页)----------------------(1)13(2)1024,0,
1023
(3)8192,1024(4)2^30,2^20,2^10(5
redennc
·
2020-09-15 01:41
汇编语言
汇编语言王爽第二版-课后答案以及解析
(2)1KB的存储器有1024个存储单元,存储单元的编号从0到
1023
。(3)1KB的存储器可以存储8192(2^13)个bit,1024个Byte。
Achou.Wang
·
2020-09-15 00:26
汇编语言-课后检测点答案
《汇编语言》清华大学第二版课后检测点检测点1.1(第8页)----------------------(1)13(2)1024,0,
1023
(3)8192,1024(4)2^30,2^20,2^1
Sunny123
·
2020-09-15 00:28
汇编学习
CTF-SSH私钥泄露
常用的端口0~
1023
端口,在扫描结果中查找特殊端口针对特殊端口进行探测,尤其对开发大端口的http服务进行排查‘探测大端口的
努力 现在开始
·
2020-09-14 21:16
CTF
CTF
web安全
ubuntu下安装zlib的方法
2:使用wgethttp://www.zlib.net/zlib-1.2.3.tar.gz,下载下来再自己编译,安装err:已发出HTTP请求,正在等待回应...404NotFound2016-01-
1023
wu_cai_
·
2020-09-14 08:59
Linux学习
zlib安装
HCIA笔记(6)— 传输层协议
端口分为知名端口(0-
1023
,如FTP、HTTP等)和动态端口(1024-65535,不固定分配给某个任务,只要运行程序
灰雪糕
·
2020-09-14 06:33
网络
协议
HCIA
Arduino基础学习总结
(pin,HIGH);//写高或低pinMode(pin,)//工作模式设置INPUT,OUTPUT,orINPUT_PULLUP上拉输入---模拟输入输出analogRead()读入模拟电压返回0-
1023
analogReference
CloudCver
·
2020-09-14 03:08
python时间戳与字符串转换
1.将字符串的时间转换为时间戳方法:a=“2013-10-
1023
:40:00”将其转换为时间数组importtimetimeArray=time.strptime(a,“%Y-%m-%d%H:%M:%
cuiwenxu1
·
2020-09-13 19:58
python
bzoj
1023
: [SHOI2008]cactus仙人掌图
起了个仙人掌的名字但是它并不是仙人掌(的做法)。。。。首先这个图确实是个仙人掌。。。然后如果只有树的话就可以只跑树上最长链(dfs两遍)。然而有一些比较烦人的环。所以我们考虑把它优化掉。所以把树上最长链以dp的形式实现。dp[i]代表这个点上的最长链。然后环怎么办呢,可以首先造一个dfs树,然后把环的最高点作为这个环用来dp的点,其余的点的互相连通情况在判环的过程中进行,之后这个点的dp值就是其中
zzk_233
·
2020-09-13 17:53
dp
树形dp
服务器端口号的基础知识
服务器端口因为最近正在学习nodejs的基本语法,涉及到监听端口的问题,于是就想对端口以进行了解常见端口号及其用途:公认端口(WellKnownPorts):0-
1023
,与一些特定的服务绑定,明确使用某种协议
xclhs
·
2020-09-13 17:13
nodejs
BZOJ
1023
:[SHOI2008]cactus仙人掌图(圆方树,DP,单调队列)
Description如果某个无向连通图的任意一条边至多只出现在一条简单回路(simplecycle)里,我们就称这张图为仙人掌图(cactus)。所谓简单回路就是指在图上不重复经过任何一个顶点的回路。举例来说,上面的第一个例子是一张仙人图,而第二个不是——注意到它有三条简单回路:(4,3,2,1,6,5,4)、(7,8,9,10,2,3,7)以及(4,3,7,8,9,10,2,1,6,5,4),
weixin_33794672
·
2020-09-13 17:19
【BZOJ
1023
】仙人掌图(仙人掌,动态规划)
【BZOJ
1023
】仙人掌图(仙人掌,动态规划)题面BZOJ求仙人掌的直径(两点之间最短路径最大值)题解一开始看错题了,以为是求仙人掌中的最长路径。。。后来发现看错题了一下就改过来了。。
weixin_30800987
·
2020-09-13 16:38
BZOJ
1023
[SHOI2008]cactus仙人掌图 【仙人掌DP】
题目如果某个无向连通图的任意一条边至多只出现在一条简单回路(simplecycle)里,我们就称这张图为仙人掌图(cactus)。所谓简单回路就是指在图上不重复经过任何一个顶点的回路。举例来说,上面的第一个例子是一张仙人图,而第二个不是——注意到它有三条简单回路:(4,3,2,1,6,5,4)、(7,8,9,10,2,3,7)以及(4,3,7,8,9,10,2,1,6,5,4),而(2,3)同时出
weixin_30544657
·
2020-09-13 16:28
数据结构与算法
大数据
bzoj
1023
: [SHOI2008]cactus仙人掌图
id=
1023
思路:类似树形DP记录一个f[i]表示最远(因为有环,所以这个定义是有一些限制条件的)先用点双缩点,每个环的信息可以挂到最高点上树上的差不多对于环上的,从一边扫过去,因为dis(i,j)有单调性
weixin_30477293
·
2020-09-13 16:24
[仙人掌直径 单调队列 DP] BZOJ
1023
[SHOI2008]cactus仙人掌图
题解:http://z55250825.blog.163.com/blog/static/150230809201412793151890/http://hzwer.com/4645.html#include#include#includeusingnamespacestd;typedeflonglongll;inlinecharnc(){staticcharbuf[100000],*p1=buf
里阿奴摩西
·
2020-09-13 16:24
仙人掌
DP
单调队列
bzoj
1023
(仙人掌直径,圆方树)
/**************************************************************Problem:
1023
User:zhhxLanguage:C++Result
running_in_dark
·
2020-09-13 16:24
仙人掌
BZOJ
1023
: [SHOI2008]cactus仙人掌图
题面解题思路人生第一次接触仙人掌树,仙人掌树的直径,实际上就是将很多基环树结合。f[x]表示以x为根的节点的最大深度,tarjan的目的就是求出桥,用来更新每个环的父亲的f数组与整个的ans。求出环后因为可以从环上的任意一点更新环的父亲,所以要用双端队列优化的dp来处理。这位巨佬的博客写的很好很明白(https://blog.csdn.net/corsica6/article/details/79
妖怪吧
·
2020-09-13 16:31
图论--仙人掌
【BZOJ
1023
】【SHOI2008】仙人掌图
【题目链接】点击打开链接【思路要点】建立圆方树,并进行树形DP,求出每个圆点到其子树内最远的圆点的距离\(dp_{i,0}\),以及在不同的子树内距离最远的圆点的距离\(dp_{i,1}\)。考虑枚举直径上离根最近的点:若该点为圆点,那么该圆点对答案的贡献显然为\(dp_{i,0}+dp_{i,1}\)。若该点为方点,那么问题便转化为了“在一个\(N\)个点的环上有一系列点,每个点有权值\(val
cz_xuyixuan
·
2020-09-13 16:57
【OJ】BZOJ
【类型】做题记录
【数据结构】圆方树
【数据结构】队列与单调队列
【算法】动态规划
bzoj
1023
: [SHOI2008]cactus仙人掌图
题意:给一颗仙人掌,求它的直径。有关的定义题目中说的很清楚,就不再重复了。首先假如给的是一棵树,求树的直径,就比较简单,可以dfs或bfs。考虑dp的做法。设集合g表示i到其各个子树的最长链链,即以i为最高点,且除端点外,没有相交的不同最长链。(语文死得早,意会下吧)于是过i,且完全在其子树中的最长链是g中最大的+次大的。其长度记为F。直径显然存在唯一最高点,所以ans=Max{F1,F2,F3,
fyc_kabuto
·
2020-09-13 16:39
仙人掌图
bzoj
1023
[SHOI2008]cactus仙人掌图 树形DP+单调队列
题意:给一颗仙人掌求直径。经典好题。一开始naive的想以为缩点以后直接求,想了想感觉自己是傻子。。块内的根本无法统计。大概能想到DP求解,但是单调队列真心被震惊到了==设f[x],表示以x为起点(从上往下)的最长路径,对于树边/非树边分别转移,树边当让直接转移了,主要是非树边,非树边就是环上边,我只用环上的点更新f[x](x为环上深度最小点),这个需要DP。树边情况,对于f[x],有f[x]=m
Transcendence_magia
·
2020-09-13 16:03
bzoj
DP
神奇脑洞题
单调队列
树形DP
BZOJ
1023
: [SHOI2008]cactus仙人掌图(单调队列优化DP)
传送门题意:求一颗仙人掌的直径。题解:DP。首先建出图的DFS树。因为是仙人掌图,所以每个环必定有一个dfs序最小的点,连接着若干条后向边和树边,表示环上的边或者割边。记录f[i]表示dfs树上以i为根的子树(子图)中最长链。考虑DP:1.对于一条割边,对答案的影响为f[i]+f[v]+1,之后直接f[i]=max{f[i],f[v]+1}。2.对于环边先不处理,等到dfs完所有子树后重新枚举边查
DZYO
·
2020-09-13 16:03
DP及DP优化
BZOJ
1023
[SHOI2008]cactus仙人掌图
仙人掌DP,f[i]表示i的子仙人掌里以i为一个端点走最短路的最长链dfs一颗仙人掌,带上tarjan的low和dfn,对于一个点,如果是这个环的根,用这个环上的所有点转移,如果不是这个环的根,不用这个环上的点转移。#include#include#include#include#include#include#include#include#include#include#include#inc
neither_nor
·
2020-09-13 16:30
仙人掌
BZOJ
【bzoj
1023
】[SHOI2008]cactus仙人掌图
http://z55250825.blog.163.com/blog/static/150230809201412793151890/%%%%反正自己就是sb。。第一道仙人掌dp。。。感觉很神奇啊#include#include#includeusingnamespacestd;charc;inlinevoidread(int&a){a=0;doc=getchar();while(c'9');wh
Hillan_
·
2020-09-13 15:14
仙人掌
DP
Luogu 4244 [SHOI2008]仙人掌图
BZOJ
1023
如果我们把所有的环都缩成一个点,那么整张图就变成了一棵树,我们可以直接$dp$算出树的直径。
dashu497731727
·
2020-09-13 15:10
1023
: [SHOI2008]cactus仙人掌图
Description如果某个无向连通图的任意一条边至多只出现在一条简单回路(simplecycle)里,我们就称这张图为仙人掌图(cactus)。所谓简单回路就是指在图上不重复经过任何一个顶点的回路。举例来说,上面的第一个例子是一张仙人图,而第二个不是——注意到它有三条简单回路:(4,3,2,1,6,5,4)、(7,8,9,10,2,3,7)以及(4,3,7,8,9,10,2,1,6,5,4),
cx_lzx
·
2020-09-13 15:37
仙人掌
BZOJ
1023
[SHOI2008]cactus仙人掌图:圆方树+单调队列DP
题目传送门题意:给出一个仙人掌图,边权都为1,求其直径。仙人掌图:无向图的每条边至多存在于一个简单环中。仙人掌图直径:Max(dis(u,v))1#definepb(x)push_back(x)usingnamespacestd;constintmaxn=1e5+100;vectorE1[maxn],ET[2*maxn],LenT[2*maxn];intdfn[maxn],fa[2*maxn],l
calabash_boy
·
2020-09-13 15:10
仙人掌
BZOJ
POJ
洛谷
【DP】 BZOJ
1023
: [SHOI2008]cactus仙人掌图
分成环形dp和树形dp,然后环形dp用单调队列做。。。。#include#include#include#include#include#include#include#include#include#include#include#include#include#definemaxn50005#definemaxm20000005#defineeps1e-7#definemod100000000
yysys
·
2020-09-13 15:05
DP
【BZOJ
1023
】 [SHOI2008]cactus仙人掌图
1023
:[SHOI2008]cactus仙人掌图TimeLimit:1SecMemoryLimit:162MBSubmit:1235Solved:482[Submit][Status]Description
Regina8023
·
2020-09-13 15:11
~Tree
Problems~
BZOJ
1023
SHOI2008 cactus仙人掌图 仙人掌DP
题目大意:给定一棵仙人掌,求这棵仙人掌的直径首先Tarjan缩点双,开vector或者链表记录每个点属于哪些点双,以及每个点双中有哪些点有些点双可能不是环,我们可以补上一条边看成环,无伤大雅每次DP时,首先枚举环的根节点以外的点,对这些点所在的其它点双DP一遍然后令f[x]为以x为根的子仙人掌的所有点和x之间的最大距离然后我们将环倍增用单调队列来更新答案保证决策点和被更新点的距离不超过环长度的一半
PoPoQQQ
·
2020-09-13 15:07
BZOJ
Tarjan
单调队列
树形DP
[BZOJ]
1023
cactus仙人掌图(SHOI2008)
NOIP后的第一次更新嗯。Description如果某个无向连通图的任意一条边至多只出现在一条简单回路(simplecycle)里,我们就称这张图为仙人掌图(cactus)。所谓简单回路就是指在图上不重复经过任何一个顶点的回路。举例来说,上面的第一个例子是一张仙人图,而第二个不是——注意到它有三条简单回路:(4,3,2,1,6,5,4)、(7,8,9,10,2,3,7)以及(4,3,7,8,9,1
L183287669
·
2020-09-13 15:53
bzoj
1023
: [SHOI2008]cactus仙人掌图
这道题是我做的第一道仙人掌DP,小小纪念一下……仙人掌DP就是环上的点环状DP,树上的点树上DP。就是说,做一遍DFS,DFS的过程中处理出环,环上的点先不DP,先把这些换上的点的后继点都处理出来,再从环上DFS序最小的点开始进行环状DP,就ok了。但是注意判断是不是父边不能用v[k]!=fa[now],这样如果两个点构成一个环就会出错,所以存这个点的父边,记为fb[now],这样判断的时候只需判
weixin_33963594
·
2020-09-13 14:12
1023
: [SHOI2008]cactus仙人掌图 - BZOJ
Description如果某个无向连通图的任意一条边至多只出现在一条简单回路(simplecycle)里,我们就称这张图为仙人图(cactus)。所谓简单回路就是指在图上不重复经过任何一个顶点的回路。举例来说,上面的第一个例子是一张仙人图,而第二个不是——注意到它有三条简单回路:(4,3,2,1,6,5,4)、(7,8,9,10,2,3,7)以及(4,3,7,8,9,10,2,1,6,5,4),而
weixin_30951231
·
2020-09-13 14:10
洛谷 P4244 [SHOI2008]仙人掌图 II 解题报告
但是实际上还是和bzoj
1023
是一个题目的。题目描述如果某个无向连通图的任意一条边至多只出现在一条简单回路(simplecycle)里,我们就称这张图为仙人掌图(cactus)。
weixin_30757793
·
2020-09-13 14:09
BZOJ
1023
: [SHOI2008]cactus仙人掌图
建出圆方树像普通找直径那样dp一下环上的dp要维护一个单调队列code:#include#include#include#include#include#include#include#include#include#include#include#include#include#include#include#include#include#definelllonglong#defineinf1
L_0_Forever_LF
·
2020-09-13 14:02
BZOJ
DP
仙人掌
上一页
8
9
10
11
12
13
14
15
下一页
按字母分类:
A
B
C
D
E
F
G
H
I
J
K
L
M
N
O
P
Q
R
S
T
U
V
W
X
Y
Z
其他