自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(204)
  • 资源 (3)
  • 收藏
  • 关注

原创 GUAVA-Strings类

方法 作用 传参类型 返回类型 实现方法 复杂度 nullToEmpty null转换为”“ String String O(1) emptyToNull 如上相反操作 padStart 在字符串中添加定长前缀字符 String,int,char String 利用String...

2018-07-15 19:47:20 1090

原创 GUAVA-Ints类

方法 作用 传参类型 返回类型 实现方法 复杂度 hashCode 返回int型的hash值(直接用溢出当作hash) int int 直接返回int型的value O(1) checkedCast 检查参数是否超过int范围 long int 强转为int,越界则报错 O(1) saturatedCa...

2018-07-15 18:13:29 1133

原创 Git基本使用操作

Git是一个开源的分布式版本控制系统,通过对分支的管理,合并,可以有效、高速的处理从很小到非常大的项目版本管理。 1.Git基本框架 其基本框架如下: 从图中可以看到,Git分为三种工作状态和工作区域,当文件被创建和修改时,Git出于Modified态,此时的文件位于Git的工作区,这也意味着其此时不存在于本地仓库中,不能达到版本分支的效果;将本地数据修改后通过git a...

2018-07-13 22:24:55 1411

原创 HDU 5025 Saving Tang Monk (状压搜索)

题意:地图上K开始按照1~m的顺序取完所有钥匙到达T的最小步数,如果遇到step+1,再次遇到不加 题解:以一个思维状态数组表示当前状态是否被访问过,四维唯别为,x,y坐标维,钥匙状态,S状态#include<cstring>#include<string>#include<iostream>#include<queue>#include<cstdio>#include<algorith

2016-11-09 22:16:39 463

原创 HDU 4123 (树的直径+单调队列求差值小于等于k的最长子区间)

题意:给出一棵树,结点编号1~n,设每个结点到树上最远距离为Li,m次询问每次询问1~n中连续区间中差值小于等于q的最长子区间长度 题解:首先肯定是要用树的直径处理出每个结点的最远距离,接下来就直接O(n*m)吧,试过不会T,每次询问都扫一遍整个数组得到最长子区间。 最长子区间求法可以单调队列,也可以用RMQ预处理#include<cstring>#include<string>#inclu

2016-11-08 21:24:25 537

原创 HDU 4046 Panda (分块 或 线段树区间合并)

题面挺美的 题意:给出一个字符串,两种操作1.询问区间[l,r]内wbw有多少个(可重叠)2.将位置x的字符改为c 题解:分块和线段树都可以搞,分块很好解释,只需要单独处理边界问题。线段树区间合并需要将每次询问的区间拿出来单独处理一次。分块:#include<cstring>#include<string>#include<iostream>#include<queue>#include

2016-10-31 22:52:43 356

原创 HDU 4777 Rabbit Kingdom(离线树状数组 预处理)

题意:询问区间内与其它数不互质的数有多少个 题解:看了众多大牛的博客才懂这题怎么写(我好菜啊) 对于每一次询问,如果知道了这个数的左边不互质区间和右边不互质区间,那么就能通过离线之后加加减减的方法得到答案。 1.不互质区间处理:对于整个序列,从左扫一遍,再从右扫一遍,扫的时候记录每个数的素因子出现的位置,不断更新素因子位置得到每个数的不互质区间L,RL,R; 2.离线处理答案:对于所有询问离

2016-10-30 17:41:06 317

原创 HihoCoder 1233 Boxes(bfs打表)

题意:给出一列箱子,小箱子只能往大箱子上面放,问最少需要多少步使箱子严格升序排列题解: 离散化大小之后得到7种箱子,那么状态总数最多777^7种,直接预处理所有情况打表,由于每一个箱子都有唯一的坐标,直接以此为关键值得到一个十进制整数作为当前状态存储访问标记和答案。#include<cstring>#include<string>#include<iostream>#include<queu

2016-10-27 23:35:42 333

原创 CodeForces 551E GukiZ and GukiZiana (分块)

题意: 给出一个序列,两种操作 1.将区间[l,r]上的数加x 2.询问满足a[i]=x的下标中下标最大距离,即找到序列右边值等于x的下标和左边等于x的下标,输出差值,如果没有找到,输出-1 题解: 二分,妥妥的#include<cstring>#include<string>#include<iostream>#include<queue>#include<cstdio>#in

2016-10-14 18:59:20 343

原创 CodeForces 455D Serega and Fun (分块+双端队列)

题意:给出一个序列,两种操作 1.将区间[l,r]滚动一次 2.询问区间[l,r]中值等于k的数有多少个 在线分块之后,两种操作都能在sqrt(n)的复杂度内解决,将每个块都设置为队列,这样滚动起来非常方便一开始没有看到数值的范围,直接用的分块+bitset+双端队列,结果T了,后来看到了这一点,想写个分块+循环队列,结果发现编程复杂度太高..(好菜)…最终还是分块+双端队列…#include

2016-10-12 11:35:11 1602

原创 HDU 5919 Sequence II(主席树)

题意:给出一个长度为n的序列,m次询问,每次询问取出【l,r】区间内所有第一次出现的数字下标,输出这些下标的中位数,强制在线分析:由于需要强制在线处理,并且没有修改,所以考虑用主席树,统计第一次出现的数字下标,直接倒着扫一遍数组建树,每一次询问,统计区间个数,二分查找第k个数,复杂度mlog(n)mlog(n)#include<cstring>#include<string>#include<i

2016-10-07 10:06:30 353

转载 UML类图中箭头和线条的含义和用法

UML类图中箭头和线条的含义和用法在学习UML过程中,你经常会遇到UML类图关系,这里就向大家介绍一下UML箭头、线条代表的意义,相信通过本文的介绍你对UML中箭头、线条的意义有更明确的认识。

2017-05-23 09:57:25 883

转载 [转]EAX、ECX、EDX、EBX寄存器的作用

戳我转到原文地址 一般寄存器:AX、BX、CX、DX AX:累积暂存器,BX:基底暂存器,CX:计数暂存器,DX:资料暂存器索引暂存器:SI、DI SI:来源索引暂存器,DI:目的索引暂存器堆叠、基底暂存器:SP、BP SP:堆叠指标暂存器,BP:基底指标暂存器EAX、ECX、EDX、EBX:為ax,bx,cx,dx的延伸,各為32位元 ESI、EDI、ESP、EBP:為si,di,sp,

2017-04-19 20:03:59 855

原创 Window Pains POJ 2585

Description Boudreaux likes to multitask, especially when it comes to using his computer. Never satisfied with just running one application at a time, he usually runs nine applications, each in it

2017-04-12 13:53:02 510

原创 Idiomatic Phrases Game HDU 1546

DescriptionTom is playing a game called Idiomatic Phrases Game. An idiom consists of several Chinese characters and has a certain meaning. This game will give Tom two idioms. He should build a list

2017-04-12 13:52:58 424

原创 POJ 1270 Following Orders 拓扑排序全输出

Description Order is an important concept in mathematics and in computer science. For example, Zorn's Lemma states: ``a partially ordered set in which every chain has an upper bound contains a max

2017-04-12 13:52:53 749

原创 CodeForces 518C Anya and Smartphone

DescriptionAnya has bought a new smartphone that uses Berdroid operating system. The smartphone menu has exactly n applications, each application has its own icon. The icons are located on differe

2017-04-12 13:52:48 442

原创 Cards CodeForces 399C

DescriptionUser ainta loves to play with cards. He has a cards containing letter "o" and b cards containing letter "x". He arranges the cards in a row, and calculates the score of the deck by the

2017-04-12 13:52:43 638

原创 CodeForces 25D Roads not only in Berland

Time Limit:2000MS     Memory Limit:262144KB     64bit IO Format:%I64d & %I64uSubmit Status Practice CodeForces 25DDescriptionBerland Government decided to improve relations with neighboring

2017-04-12 13:52:39 407

转载 【转】别人家的八数码 A* IDA*解法

【转】 http://www.cnblogs.com/liyongmou/archive/2010/07/19/1780861.html  1 代码 2 3 // A* 4 #include 5 #include 6 #include 7 #include 8 #include 9 using namespace std; 1

2017-04-12 13:52:35 422

原创 Maze Stretching Poj3897 二分+BFS

DescriptionUsually the path in a maze is calculated as the sum of steps taken from the starting point until the ending point,assuming that the distance of one step is exactly 1. Lets assume that

2017-04-12 13:52:31 393

原创 Data Handler 大模拟 + 双端链表 hdu 4268

E - Data Handler Time Limit:10000MS     Memory Limit:32768KB     64bit IO Format:%I64d & %I64uSubmit StatusDescription   You are in charge of data in a company, so you are called "Data H

2017-04-12 13:52:28 531

原创 二分

1 #include 2 #include 3 #include 4 #include 5 #include 6 #define AA struct ss 7 using namespace std; 8 9 int n;10 AA {11 double b,w,d,h;12 }re[50005];13 14 double P(doub

2017-04-12 13:52:24 327

原创 Stock 贪心经典 Zoj2921

Optiver sponsored problem.After years of hard work Optiver has developed a mathematical model that allows them to predict wether or not a company will be succesful. This obviously gives them a great

2017-04-12 13:52:20 361

原创 D. Block Tower

time limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputAfter too much playing on paper, Iahub has switched to computer games. T

2017-04-12 13:52:15 367

原创 烦人的dp

1050 1 #include 2 #include 3 #include 4 5 using namespace std; 6 7 int main() 8 { 9 int n;10 while(cin>>n)11 {12 int a[200][200];13 memset(a

2017-04-12 13:52:11 282

原创 搜索

1010 1 #include 2 #include 3 #include 4 #include 5 6 using namespace std; 7 8 int n,m,time,ok,dir[][5]={{1,0},{-1,0},{0,1},{0,-1}},dx,dy; 9 char g[200][200];10 11 void dfs(

2017-04-12 13:52:06 119

原创 hdu 一个人的旅行

Time Limit:1000MS     Memory Limit:32768KB     64bit IO Format:%I64d & %I64uDescription虽然草儿是个路痴(就是在杭电待了一年多,居然还会在校园里迷路的人,汗~),但是草儿仍然很喜欢旅行,因为在旅途中 会遇见很多人(白马王子,^0^),很多事,还能丰富自己的阅历,还可以看美丽的风景……草儿想去很多地

2017-04-12 13:52:02 274

原创 IP的计算

Time Limit: 3000/1000 MS (Java/Others)    Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 8633    Accepted Submission(s): 1706Problem Description在网络课程上,我学到了很多有关IP的知识。IP全称叫网际协议,有时我们

2017-04-12 13:51:53 320

原创 C. Drazil and Factorial

time limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputDrazil is playing a math game with Varda.Let's define for positive inte

2017-04-12 13:51:49 628

原创 B. Drazil and His Happy Friends

time limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputDrazil has many friends. Some of them are happy and some of them are unhap

2017-04-12 13:51:45 351

原创 A. Drazil and Date

time limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard outputSomeday, Drazil wanted to go on date with Varda. Drazil and Varda live on C

2017-04-12 13:51:41 428

原创 龟兔赛跑

Time Limit:1000MS     Memory Limit:32768KB     64bit IO Format:%I64d & %I64uDescription 据说在很久很久以前,可怜的兔子经历了人生中最大的打击――赛跑输给乌龟后,心中郁闷,发誓要报仇雪恨,于是躲进了杭州下沙某农业园卧薪尝胆潜心修炼,终 于练成了绝技,能够毫不休息得以恒定的速度(VR m/s)一直跑

2017-04-12 13:51:37 468

原创 神、上帝以及老天爷

Time Limit:1000MS     Memory Limit:32768KB     64bit IO Format:%I64d & %I64uDescription HDU 2006'10 ACM contest的颁奖晚会隆重开始了! 为了活跃气氛,组织者举行了一个别开生面、奖品丰厚的抽奖活动,这个活动的具体要求是这样的: 首先,所有参加晚会的人员都将一张

2017-04-12 13:51:31 286

原创 不容易系列之(3)―― LELE的RPG难题

Time Limit:1000MS     Memory Limit:32768KB     64bit IO Format:%I64d & %I64uSubmit StatusDescription 人称“AC女之杀手”的超级偶像LELE最近忽然玩起了深沉,这可急坏了众多“Cole”(LELE的粉丝,即"可乐"),经过多方打探,某资深Cole终于知道了原因,原来,LELE最近

2017-04-12 13:51:27 349

原创 Phone List hdu1671

Time Limit: 3000/1000 MS (Java/Others)    Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 11669    Accepted Submission(s): 3970Problem DescriptionGiven a list of phone numbers, det

2017-04-12 13:51:22 312

原创 B. Han Solo and Lazer Gun

time limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard outputThere are n Imperial stormtroopers on the field. The battle field is a plan

2017-04-12 13:51:18 422

原创 A. Chewbaсca and Number

time limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard outputLuke Skywalker gave Chewbacca an integer number x. Chewbacca isn't good at

2017-04-12 13:51:14 391

原创 阿牛的EOF牛肉串

Time Limit:1000MS     Memory Limit:32768KB     64bit IO Format:%I64d & %I64Description 今年的ACM暑期集训队一共有18人,分为6支队伍。其中有一个叫做EOF的队伍,由04级的阿牛、XC以及05级的COY组成。在共同的集训生活中,大 家建立了深厚的友谊,阿牛准备做点什么来纪念这段激情燃烧的岁月,想

2017-04-12 13:51:10 302

原创 Leftmost Digit

DescriptionGiven a positive integer N, you should output the leftmost digit of N^N. Input The input contains several test cases. The first line of the input is a single integer T whi

2017-04-12 13:51:06 293

jdk1.8.0-181-linux64.tar.gz

仅用于学习用,jdk1.8.0_181_linux64.tar.gz,jdk1.8.0_181

2022-11-03

2017年北邮803计算机学科基础综合真题参考答案(学生整理,非官方)

2017年北邮803计算机学科基础综合真题参考答案(学生整理,非官方),试题请自行从北邮研招网下载。。

2017-12-01

2016年北邮803计算机学科基础综合真题参考答案(学生整理,非官方)

2016年北邮803计算机学科基础综合真题参考答案(学生整理,非官方) 试题请自行从北邮研招网下载

2017-10-28

WinPcap-中文技术文档.doc

WinPcap-中文技术文档介绍了pcap中的接口,使用方法,源代码

2017-02-01

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除