自定义博客皮肤VIP专享

*博客头图:

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

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

博客底图:

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

栏目图:

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

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+

爱梦者的心之旅

这里记载我的回忆

  • 博客(43)
  • 收藏
  • 关注

转载 大数乘法除法

void Big_Mul() { int lena=strlen(a),lenb=strlen(b); int lenans=lena+lenb-1; for(int i=0;i<=(lena-1)/2;i++) swap(a[i],a[lena-1-i]); //数组逆置 for(int i=0;i<=(lenb-1)/2;i++) swap(b[i],

2017-01-17 20:16:36 360

原创 大数加减法

大数加法 int num1

2017-01-17 20:11:48 408

原创 hrbust 1104 计算几何

相交平行重合 相交用公式套。。。 Leyni, LOLI and Line Time Limit: 1000 MS Memory Limit: 65536 K Total Submit: 241(92 users) Total Accepted: 132(87 users) Rating:  Special Jud

2017-01-27 11:32:48 233

原创 hrbust 1126 HLG 矩阵快速幂

再来一个模板题 这题也是找递推的矩阵 1 1 1 1 0 0 0 1 0 Final Destination II Time Limit: 1000 MS Memory Limit: 65536 K Total Submit: 392(116 users) Tota

2017-01-26 16:20:14 276

原创 hrbust 1430 矩阵快速幂

第一次接触矩阵快速幂 懂了大题的思想 矩阵推理的时候有点问题 这题是我们求出 向上三角行的个数 套用学长的图 序号 向上的三角形个数 向下的三角形个数 0 1 0 1 3 1 2 10 6 3 36 28 不难观察出规律

2017-01-26 16:12:39 356

原创 hrbust 1563 亲和数

a的i倍的数b,a是b的真因子数   亲和数 Time Limit: 1000 MS Memory Limit: 10240 K Total Submit: 138(80 users) Total Accepted: 78(75 users) Rating:  Special Judge: No

2017-01-25 19:26:35 495

原创 hrbust 哈理工 2252 完全背包模板题

世界 Time Limit: 10000 MS Memory Limit: 32768 K Total Submit: 151(51 users) Total Accepted: 56(41 users) Rating:  Special Judge: No Description 世界是一个非

2017-01-25 00:23:58 515

原创 哈理工 hrbust 1019

主要选择二分对象 可以是角度 半径 或者式h h的时候需要用一个半径公式r = (L*L+4*mid*mid)/(8*mid); Expanding Rods Time Limit: 1000 MS Memory Limit: 65536 K Total Submit: 284(125 users) Total

2017-01-22 19:58:03 210

原创 hrbust 哈理工 1013

1.桶排 2.二分 主要是讲关系式分为左右两部分 Eqs Time Limit: 5000 MS Memory Limit: 65536 K Total Submit: 661(282 users) Total Accepted: 393(261 users) Rating:  Special Judge: No

2017-01-22 10:17:09 256

原创 hrbust 哈理工 1289 编辑距离

状态转移方程dp[i][j]=min(min(dp[i-1][j]+1,dp[i][j-1]+1),dp[i-1][j-1]+c); i代表a字符串 j代表b字符串 c起判断作用判断的是a[i]是否等于b[j] 每一次的移动代表的是对应位置最少移动几次 分别判断 编辑距离 Time Limit: 1000 MS Memory Limit:

2017-01-22 01:50:03 184

原创 哈理工 1291 受到攻击

判断一个点是否在凸多边形内可以用叉乘 叉乘概念大家都知道,向量a和向量b的叉积的绝对值表示以向量a和向量b为两边形成的平行四边形的面积。 S=∣a*b∣ 其中S表示以向量a和向量b为两边形成的平行四边形的面积,以此类推,那么(1/2)*S就可以表示以向量a和向量b为两边形成的三角形的面积。 假设三角形的3的顶点分别为P1(x1,y1),P2(x2,y2),P3(x3,y3),则向量a可表示

2017-01-22 01:28:14 258

原创 哈理工 hrbust 1328 相等的最小公倍数

规律题。。。。。 仔细想一下如果这个数是素数那么它一定不相等 如果的分子中所有的分子没有一对是素数的,对,,你没看错就是一对 因为一对因子如果都不是素数那么她的最大公约数就不是n n只是她的最大公约数的一个倍数对不。。 所以我们要找因子数是素数的而且一对都是素数的。。 这样他们的乘机就是n 前面坑定用不上他俩。。 所以我们主要扫的就是n到底有没有素数的因子对 相等

2017-01-21 21:48:37 280

原创 hdu EXCEL排序

结构体排序 会sort strcmp 就好。。 注意三种排序方式 选择一下就好了 注意数组大小 我re一发mle一发 D - EXCEL排序 Time Limit: 5000 MS Memory Limit: 32768 KB 64-bit integer IO format: %I64d , %I64u Java class name: Main [Subm

2017-01-21 17:19:54 342 2

原创 hrbust 2242 沼跃鱼

这个题就是对字符串遍历一下 不要忽视大小写就好 沼跃鱼 Time Limit: 500 MS Memory Limit: 32768 K Total Submit: 507(280 users) Total Accepted: 299(267 users) Rating:  Special Judge: No

2017-01-21 17:18:05 316

原创 hrbust Function Run Fun

这题就怕te 递归可以 也可以直接迭代出所有情况 关系式别看错了就好 Function Run Fun Time Limit: 1000 MS Memory Limit: 65536 K Total Submit: 380(184 users) Total Accepted: 198(170 users) Rat

2017-01-21 17:13:41 262

原创 Tiles of Tetris, NOT!

看着题挺长的其实就是给你一个长方形 让你找出最小块数能够拼成正方形 数学题不做太多解释 B - Tiles of Tetris, NOT! Time Limit: 1000 MS Memory Limit: 65536 KB 64-bit integer IO format: %lld , %llu Java class name: Main [Submit] [S

2017-01-21 17:10:53 308

原创 hrbust 哈理工 统计地雷数量

暴力扫图 一开始将图形清空遍历图中’。‘的8个方向点 G - 统计地雷数量 Time Limit: 1000 MS Memory Limit: 65536 KB 64-bit integer IO format: %lld , %llu Java class name: Main [Submit] [Status] Description C++群

2017-01-21 17:07:09 411

原创 哈理工 hrbust 正确的日期格式

这题写足判断 记住闰年平年 大月小月份还有2月 输入的时候可能存在空格所以用gets读入是最安全的 Description 这个题目要你判断题目给的日期格式是否符合格式。 我们先定义日期的格式:yyyy-mm-dd,就是年-月-日,年份占四位,月份占两位,日占两位,不足的用前导0补齐,年月日之间以"-"分隔。 Input 有多组测试数据,每组

2017-01-21 17:04:23 339

原创 今年暑假不AC

贪心问题 结构体排序 sort处理结束时间 找变量标记节目开始时间就好。 具体操作看代码 Description “今年暑假不AC?” “是的。” “那你干什么呢?” “看世界杯呀,笨蛋!” “@#$%^&*%...” 确实如此,世界杯来了,球迷的节日也来了,估计很多ACMer也会抛开电脑,奔向电视了。 作为球迷,一定想看尽量多的完整的比赛,当然,作为新

2017-01-21 17:01:16 270

原创 hdu 1874 畅通工程续 floyd

某省自从实行了很多年的畅通工程计划后,终于修建了很多路。不过路多了也不好,每次要从一个城镇到另一个城镇时,都有许多种道路方案可以选择,而某些方案要比另一些方案行走的距离要短很多。这让行人很困扰。 现在,已知起点和终点,请你计算出要从起点到终点,最短需要行走多少距离。 Input 本题目包含多组数据,请处理到文件结束。 每组数据第一行包含两个正整数N和M(0#include<stdio.h>

2017-01-20 20:32:16 495

原创 hdu 5475 An easy problem

Problem Description One day, a useless calculator was being built by Kuros. Let’s assume that number X is showed on the screen of calculator. At first, X = 1. This calculator only supports two types o

2017-01-20 20:29:02 225

原创 hdu 5949 Relative atomic mass

水题 求分子式的质量 Problem Description Relative atomic mass is a dimensionless physical quantity, the ratio of the average mass of atoms of an element (from a single given sample or source) to 12of the mass

2017-01-20 20:25:37 388

原创 hdu 5461 Largest Point

Problem Description Given the sequence A with n integers t1,t2,⋯,tn. Given the integral coefficients a and b. The fact that select two elements ti and tj of A and i≠j to maximize the value of at2i+btj

2017-01-20 20:23:48 172

原创 hdu 3665 seaside floyd

Seaside Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others) Total Submission(s): 955 Accepted Submission(s): 679Problem Description XiaoY is living in a big city,

2017-01-20 20:20:08 239

原创 uvalive 5092 - Permutation Counting

Given a permutation a1, a2, … aN of {1, 2, … , N}, we define its E-value as the amount of elements where ai > i. For example, the E-value of permutation {1, 3, 2, 4} is 1, while the E-value of {4, 3,

2017-01-20 20:17:41 303

原创 UVALive - 7077 Assignments

Zu Chongzhi (429–500) was a prominent Chinese mathematician and astronomer during the Liu Song and Southern Qi Dynasties. Zu calculated the value of| to the precision of six decimal places and for a

2017-01-20 20:15:16 493

原创 hdu 5211Mutiple

WLD likes playing with a sequence a[1..N]a[1..N]. One day he is playing with a sequence of NN integers. For every index i, WLD wants to find the smallest index F(i)F(i) ( if exists ), that i#include<st

2017-01-20 20:09:13 197

原创 hdu 5210 Delete

WLD likes playing with numbers. One day he is playing with NN integers. He wants to delete KK integers from them. He likes diversity, so he wants to keep the kinds of different integers as many as poss

2017-01-20 20:03:51 272

原创 hdu Card Game

Card GameSoda and Beta are good friends. They are going to play a card game today. Soda has nn cards with number a1,a2,…,ana1,a2,…,an while Beta has nn cards with number b1,b2,…,bnb1,b2,…,bn. First, th

2017-01-20 19:59:49 324

原创 哈理工 1812 小乐乐想出门

小乐乐想出门 Time Limit: 1000 MS Memory Limit: 32768 K Total Submit: 329(212 users) Total Accepted: 260(208 users) Rating: Special Judge: No Description 大家可能不知道,小乐乐的家好大好大,可是好乱好乱。下面那个矩阵就是她家的简化图,每一

2017-01-18 12:08:10 218

原创 哈理工 1143 泉水

泉水 Time Limit: 1000 MS Memory Limit: 65536 K Total Submit: 1890(460 users) Total Accepted: 726(413 users) Rating: Special Judge: No Description Leyni是一个地址调查员,有一天在他调查的地方突然出现个泉眼。由于当地的地势不均匀,

2017-01-18 12:05:15 349

原创 哈理工 1943

马是走“日”的 Time Limit: 1000 MS Memory Limit: 32768 K Total Submit: 151(86 users) Total Accepted: 90(81 users) Rating: Special Judge: No Description xuxu闲来无事,去买了盘象棋,准备参加下届哈理工象棋大赛,(xuxu有一个特异功能,他能

2017-01-18 12:01:53 228

原创 哈理工 1930

PROBLEM-ONE Time Limit: 1000 MS Memory Limit: 32768 K Total Submit: 214(108 users) Total Accepted: 85(72 users) Rating: Special Judge: No Description xuxu这几天在学习斐波纳契数,他发现当n很大的时候,这个斐波那契数是非常

2017-01-17 20:27:26 305

翻译 哈理工1316 移动2

移动 II Time Limit: 1000 MS Memory Limit: 65536 K Total Submit: 451(130 users) Total Accepted: 200(120 users) Rating: Special Judge: No Description 在坐标轴[0,500]上存在两点A,B。点A可以多次移动,每次移动需要遵循如下规则:1

2017-01-17 20:25:19 209

原创 哈理工 1596 序列问题1

序列问题I Time Limit: 1000 MS Memory Limit: 32768 K Total Submit: 329(156 users) Total Accepted: 159(136 users) Rating: Special Judge: No Description 给一个长度为n的整数序列A0,A1,……An-1,找出俩个整数Ai和Aj(i < j)

2017-01-17 12:59:41 424

原创 hrbust 1597 序列问题II

序列问题II Time Limit: 1000 MS Memory Limit: 32768 K Total Submit: 202(90 users) Total Accepted: 95(83 users) Rating: Special Judge: No Description 给一个长度为n的整数序列A0,A1,……An-1,找出最长的非递增子序列的长度 Input

2017-01-17 11:47:01 604

转载 hrbust 1216

数的划分 Time Limit: 1000 MS Memory Limit: 65535 K Total Submit: 184(89 users) Total Accepted: 125(87 users) Rating: Special Judge: No Description 将整数n分成k份,且每份不能为空,任意两份不能相同(不考虑顺序)。 例如:n=7,k=3,下面

2017-01-17 00:16:08 397

原创 哈理工1140 数字问题

数字和问题 Time Limit: 1000 MS Memory Limit: 65536 K Total Submit: 740(211 users) Total Accepted: 236(175 users) Rating: Special Judge: No Description 定义一种操作为:已知一个数字,对其各位数字反复求和,直到剩下的数是一位数不能求和为止。

2017-01-16 21:53:16 921

原创 hrbust 1170 语法检查

语法检查-括号匹配 Time Limit: 1000 MS Memory Limit: 65536 K Total Submit: 571(151 users) Total Accepted: 178(135 users) Rating: Special Judge: No Description 欢迎大家加入ACM! 要深入的学习ACM的相关知识,首先就必须学会一门编程语

2017-01-16 21:51:41 375

原创 hrbust 1160 吸血鬼

吸血鬼 Time Limit: 1000 MS Memory Limit: 65536 K Total Submit: 403(191 users) Total Accepted: 233(184 users) Rating: Special Judge: No Description Remilia是《东方红魔馆》中首次亮相的吸血鬼角色,是有着500岁年龄的吸血鬼领

2017-01-16 21:50:06 288

空空如也

空空如也

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

TA关注的人

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