http://acm.upc.edu.cn/problem.php?id=2959 这就是个水题,之所以要写这个题是感觉很有纪念意义 用力看就是盲……23333333333333333 这个题就是最小交换几次使数组有序,首先想到的竟然是逆序数 但是逆序数是冒泡排序用的,怎么可能最小……!!!! 具体题解是: 先用结构体标记每个元素的位置和内容,然后进行排序 跟原来的数组进行比较,位置不符合,将原数组 元素 跟 本该排好序在这个位置的元素交换 然后 二分查找 结构体数组里面 该 元素 将 坐标更新…
Highways Time Limit: 1000MS   Memory Limit: 65536K Total Submissions: 26516   Accepted: 12136 Description The island nation of Flatopia is perfectly flat. Unfortunately, Flatopia has no public highways. So the traffic is difficult in Flatopia. The Fl…
Higher Math Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 2219    Accepted Submission(s): 1219 Problem Description You are building a house. You’d prefer if all the walls have a precise right…
Bus Stop 题目描述 In a rural village in Thailand, there is a long, straight, road with houses scattered along it. (We can picture the road as a long line segment, with an eastern endpoint and a western endpoint.) The Thai government is planning to set up…
原题链接 思路:水题,直接搜 #include "map" #include "queue" #include "math.h" #include "stdio.h" #include "string.h" #include "iostream" #include "algorithm" #define abs(x) x > 0 ? x : -x #define…
A.Beru-taxi 水题:有一个人站在(sx,sy)的位置,有n辆出租车,正向这个人匀速赶来,每个出租车的位置是(xi, yi) 速度是 Vi;求人最少需要等的时间: 单间循环即可: #include<iostream> #include<algorithm> #include<string.h> #include<stdio.h> #include<math.h> #include<vector> using namespace…
http://acm.fzu.edu.cn/problem.php?pid=2182 Problem 2182 水题 Accept: 188    Submit: 277Time Limit: 1000 mSec    Memory Limit : 32768 KB  Problem Description 胖哥自从当上公务员,赢取白富美,走向人生巅峰后,已经懒散到不想出题了,不仅如此,他连题目都懒得看了,现在他只会根据题目第一个单词的长度判定这个题目的难度 如果题目的第一个单词太长(长度大于3…
A. Uncowed Forces Time Limit: 20 Sec Memory Limit: 256 MB 题目连接 http://codeforces.com/contest/604/problem/A Description Kevin Sun has just finished competing in Codeforces Round #334! The round was 120 minutes long and featured five problems with maxi…
B. Archer Time Limit: 20 Sec Memory Limit: 256 MB 题目连接 http://codeforces.com/contest/312/problem/B Description SmallR is an archer. SmallR is taking a match of archer with Zanoes. They try to shoot in the target in turns, and SmallR shoots first. The…
A. Whose sentence is it? Time Limit: 20 Sec Memory Limit: 256 MB 题目连接 http://codeforces.com/contest/312/problem/A Description One day, liouzhou_101 got a chat record of Freda and Rainbow. Out of curiosity, he wanted to know which sentences were said…
/* poj1873 The Fortified Forest 凸包+枚举 水题 用小树林的木头给小树林围一个围墙 每棵树都有价值 求消耗价值最低的做法,输出被砍伐的树的编号和剩余的木料 若砍伐价值相同,则取砍伐数小的方案. */ #include<stdio.h> #include<math.h> #include <algorithm> #include <vector> using namespace std; const double eps = 1…
/* poj3348 Cows 凸包+多边形面积 水题 floor向下取整,返回的是double */ #include<stdio.h> #include<math.h> #include <algorithm> using namespace std; const double eps = 1e-8; struct point { double x,y; }; int n; point dian[10000+10],zhan[10000+10]; /////////…
#6303. 水题 内存限制 10 MiB 时间限制:1000 ms 标准输入输出 题目描述 给定正整数 n,kn, kn,k,已知非负整数 xxx 满足 n!modkx=0,求 xmaxx_{max}x​max​​ . 输入格式 本题包含多组数据,请处理至文件末尾. 对于每组数据,共有一行,两个整数,表示 n,kn, kn,k. 输出格式 对于每组数据,输出一行,一个整数,表示 xmaxx_{max}x​max​​. 样例 输入样例 10 2 5000000000000000000 2 500…
1040水题; These days, I am thinking about a question, how can I get a problem as easy as A+B? It is fairly difficulty to do such a thing. Of course, I got it after many waking nights.Give you some integers, your task is to sort these number ascending (…
Hard Disk Drive Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 83    Accepted Submission(s): 48 Problem Description Yesterday your dear cousin Coach Pang gave you a new 100MB hard disk drive (H…
Zhuge Liang's Password Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 59    Accepted Submission(s): 47 Problem Description In the ancient three kingdom period, Zhuge Liang was the most famous a…
之所以在codeforces上找这100道水题的原因是为了巩固我对最近学的编程语言的掌握程度. 找的方式在codeforces上的PROBLEMSET中过的题最多的那些题里面出现的最前面的10个题型,它们是: math(数学) brute force(暴力) strings(字符串) implementation(模拟) greedy(贪心) sortings(排序) number theory(数论) constructive algorithm dp(动态规划) shortest path(…
Children's Day Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 158    Accepted Submission(s): 72 Problem Description Today is Children's Day. Some children ask you to output a big letter 'N'. 'N…
10763:水题不解释直接贴代码. #include <iostream> #include <string.h> #include <stdio.h> #include <algorithm> #include <math.h> #include <queue> #define eps 1e-9 typedef long long ll; using namespace std; int n; ]; int main() { int…
Building bridges Time Limit: 3000/1000 MS (Java/Others)    Memory Limit: 65535/32768 K (Java/Others)Total Submission(s): 45    Accepted Submission(s): 39 Problem Description Hululu and Cululu are two pacific ocean countries made up of many islands. T…
在对银行账户等重要权限设置密码的时候,我们常常遇到这样的烦恼:如果为了好记用生日吧,容易被破解,不安全:如果设置不好记的密码,又担心自己也会忘记:如果写在纸上,担心纸张被别人发现或弄丢了... 这个程序的任务就是把一串拼音字母转换为6位数字(密码).我们可以使用任何好记的拼音串(比如名字,王喜明,就写:wangximing)作为输入,程序输出6位数字. 变换的过程如下: 第一步. 把字符串6个一组折叠起来,比如wangximing则变为: wangxi ming 第二步. 把所有垂直在同一个位置…
1222: FJ的字符串 [水题] 时间限制: 1 Sec 内存限制: 128 MB 提交: 92 解决: 20 统计 题目描述 FJ在沙盘上写了这样一些字符串: A1  =  “A” A2  =  “ABA” A3  =  “ABACABA” A4  =  “ABACABADABACABA” …  … 你能找出其中的规律并写所有的数列AN吗? 输入 仅有一个数:N  ≤  26. 输出 请输出相应的字符串AN,以一个换行符结束.输出中不得含有多余的空格或换行.回车符. 样例输入 2 3 样例输…
题目链接: Price List Time Limit: 2000/1000 MS (Java/Others)     Memory Limit: 262144/131072 K (Java/Others) Problem Description There are n shops numbered with successive integers from 1 to n in Byteland. Every shop sells only one kind of goods, and the…
看大佬做2017-WF,我这种菜鸡,只能刷刷水题,勉强维持生活. 赛后补补水题. 题目pdf链接,中文的,tls翻译的,链接在这里 个人喜欢在vjudge上面刷题. E Need for Speed 题意: 有中文题意,我就不多说了,仪表盘会有一个固定偏差,求这个. 思路: 二分答案,进行判断,二分的上下限,我是 -1 到 1e8:一开始范围错了WA掉了. #include <stdio.h> #include <iostream> #include <algorithm&g…
N! Time Limit: 10000/5000 MS (Java/Others)    Memory Limit: 262144/262144 K (Java/Others) Total Submission(s): 64256    Accepted Submission(s): 18286 Problem Description Given an integer N(0 ≤ N ≤ 10000), your task is to calculate N!   Input One N in…
水题!没其他想说的,还以为可以搞点高大上的搜索呢!十五分钟,暴力两重循环就OK了! 代码如下: #include<iostream> #include<stdio.h> #include<string.h> #include<math.h> #include<algorithm> #include<queue> #include<set> #include<vector> #include<map>…
E - 5 Time Limit:1500MS     Memory Limit:262144KB     64bit IO Format:%I64d & %I64u Submit Status Practice HDU 5391 Description Tina Town is a friendly place. People there care about each other. Tina has a ball called zball. Zball is magic. It grows…
Nasty Hacks Time Limit: 3000/1000 MS (Java/Others)    Memory Limit: 65536/32768 K (Java/Others) Total Submission(s): 3049    Accepted Submission(s): 2364 Problem Description You are the CEO of Nasty Hacks Inc., a company that creates small pieces of…
CSU 1772 漫漫上学路 Time Limit: 1000MS   Memory Limit: 131072KB   64bit IO Format: %lld & %llu Submit Status Description 对于csuxushu来说,能够在CSU(California State University)上学是他一生的荣幸.CSU校园内的道路设计的十分精巧,由n+1条水平道路和n+1条竖直道路等距交错而成,充分体现了校园深厚的文化底蕴.然而不幸的是CS市每到夏季,天降大雨,…
1050: 写一个函数,使给定的一个二维数组(3×3)转置,即行列互换 Time Limit: 1 Sec  Memory Limit: 128 MBSubmit: 154  Solved: 112[Submit][Status][Web Board] Description 写一个函数,使给定的一个二维数组(3×3)转置,即行列互换. Input 一个3x3的矩阵 Output 转置后的矩阵 Sample Input 1 2 3 4 5 6 7 8 9 Sample Output 1 4 7…