-------Pokemon Master------很水-------】的更多相关文章

link 求和比大小... /** @Date : 2017-03-23-21.26 * @Author : Lweleth (SoungEarlf@gmail.com) * @Link : https://github.com/ * @Version : */ #include<bits/stdc++.h> #define LL long long #define PII pair #define MP(x, y) make_pair((x),(y)) #define fi first #d…
这章主要是将如何将jQuery应用到网站中,或者说其实就是一些前端知识,对于我这种后端程序来说其实还是蛮有用的. 关于网站结构 文件结构 前端文件分三个文件夹放 images文件夹用来存放将要用到的图片 styles文件夹用来存放css样式表 scripts文件夹用来存放js脚本 网页结构 头部:网站的品牌log,登录信息 内容:放置网站的主体内容 尾部:放置网站的其它友情链接和版权信息之类的 关于网站样式 首先写一个样式表,来包含全局的样式.定义整个网站的reset.css样式表,编写一些全局…
Pokemon Master Time Limit : 4000/2000ms (Java/Other) Memory Limit : 131072/65536K (Java/Other) Total Submission(s) : 15 Accepted Submission(s) : 8 Problem Description Calem and Serena are pokemon masters. One day they decided to have a pokemon battle…
A. Boy or Girl time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output Description Those days, many boys use beautiful girls' photos as avatars in forums. So it is pretty hard to tell the gender of…
2205 据说题目很水 Accept: 199    Submit: 458Time Limit: 1000 mSec    Memory Limit : 32768 KB Problem Description Sunday最近对图论特别感兴趣,什么欧拉回路什么哈密顿回路,又是环又是树.在看完一本书后,他对自己特别有信心,便找到大牛牛犇犇,希望他出一题来考考自己. 在遥远的古代东方有N个城市,它们之间可以通过双向的道路相连.任意两个城市由不超过一条道路直接相连,而且没有城市的道路连向自身.但是…
D. Duff in Beach Time Limit: 1 Sec Memory Limit: 256 MB 题目连接 无 Description Master Mind KongMing gave Fei Zhang a secrete master plan stashed in a pocket. The plan instructs how to deploy soldiers on the four corners of the city wall. Unfortunately, w…
An interesting mobile game Time Limit: 3000/1000 MS (Java/Others)    Memory Limit: 65535/32768 K (Java/Others)Total Submission(s): 255    Accepted Submission(s): 123 Problem Description XQ,one of the three Sailormoon girls,is usually playing mobile g…
Problem Description Sunday最近对图论特别感兴趣,什么欧拉回路什么哈密顿回路,又是环又是树.在看完一本书后,他对自己特别有信心,便找到大牛牛犇犇,希望他出一题来考考自己. 在遥远的古代东方有N个城市,它们之间可以通过双向的道路相连.任意两个城市由不超过一条道路直接相连,而且没有城市的道路连向自身.但是牛犇犇是个纯情的小伙子,尽管他还没有女朋友,但他还是很讨厌第三者,以至于讨厌三这个数字.所以他希望Sunday能够构造一个N个城市的地图,这个地图中不能有任意三个城市能够相互…
总时间限制:  1000ms 内存限制:  65536kB 描述 一个迷宫由R行C列格子组成,有的格子里有障碍物,不能走:有的格子是空地,可以走.给定一个迷宫,求从左上角走到右下角最少需要走多少步(数据保证一定能走到).只能在水平方向或垂直方向走,不能斜着走. 输入 第一行是两个整数,R和C,代表迷宫的长和宽.( 1<= R,C <= 40)接下来是R行,每行C个字符,代表整个迷宫.空地格子用'.'表示,有障碍物的格子用'#'表示.迷宫左上角和右下角都是'.'. 输出 输出从左上角走到右下角至…
刚开始一直WA,才发现原来代码中两处减去年份.月份的天数的判断条件用的是>=,虽然最后考虑n=0要退回一天的情况,但还是WA.后来改成>的条件判断,省去了考虑n=0的麻烦,AC. 此题无非就是考虑平年.闰年,月底月末,年底年末的情况. #include <iostream> #include <string.h> #include <stdio.h> #include <cstring> #include <stdlib.h> usi…
http://acm.zju.edu.cn/onlinejudge/showProblem.do?problemCode=3776 题意:比较两组数据的总和大小. #include <iostream> using namespace std; int main() { int t; cin>>t; while(t--) { int n,m,s1=0,s2=0,a[6],b[6]; cin>>n>>m; for(int i=0; i<n; i++) {…
题目: http://poj.org/problem?id=2251 #include <stdio.h> #include <string.h> #include <queue> using namespace std; ][][]; ][][]; ][] = {{,,}, {,,}, {,,}, {,,-}, {,-,}, {-,,}}; struct Point { int x, y, z, step; }; struct Point start; queue&l…
<!doctype html> <html lang="zh-cn"> <base target="_blank" /> <meta charset="utf-8" /> <title> My first web site </title> <link rel="stylesheet" href="css/style.css" /…
链接: http://vj.acmclub.cn/contest/view.action?cid=168#problem/B Coprimes 时限:250MS     内存:4096KB     64位IO格式:%I64d & %I64u 状态 练习 SGU 102 问题描述 For given integer N (1<=N<=104) find amount of positive numbers not greater than N that coprime with N. L…
A. Reachable Numbers 题意:设f(x)为 x+1 这个数去掉后缀0的数,现在给出n,问经过无数次这种变换后,最多能得到多少个不同的数. 代码 #include<cstdio> #include<cstring> #include<iostream> #include<algorithm> #include<queue> #include<stack> #include<set> #include<…
题意:给你N 城市和M条道路,每条道路要付的钱,但是如果你在这个道路上你可以付其他道路的钱(跟走到的时候去的话不一样),问你从1走到N最少话费是多少. 直接DFS搜. 链接http://poj.org/problem?id=3411 代码: #include <stdio.h> #include <string.h> #include <iostream> #include <algorithm> #include <stdlib.h> #inc…
题意:给你N个城市和M条路和K块钱,每条路有话费,问你从1走到N的在K块钱内所能走的最短距离是多少 链接:http://poj.org/problem?id=1724 直接dfs搜一遍就是 代码: #include <stdio.h> #include <string.h> #include <iostream> #include <algorithm> #include <stdlib.h> #include <vector> #i…
Robot Time Limit: 8000/4000 MS (Java/Others)    Memory Limit: 102400/102400 K (Java/Others)Total Submission(s): 158    Accepted Submission(s): 46 Problem Description Michael has a telecontrol robot. One day he put the robot on a loop with n cells. Th…
点此看题面 大致题意: 有\(n\)件T恤衫,告诉你每件T恤衫的价格以及它正面和反面的颜色(\(1≤\)颜色的编号\(≤3\)),现在有m个顾客,已知每个人想要的衣服的颜色(一件T恤衫只要有一面的颜色满足他的需求即可),请你求出每个人所需支付的最低价格(一件T恤衫只能被买一次). 题解 由于这道题的颜色最多只有\(3\)种,因此,我们只要开\(3\)个小根堆来存储每种颜色的衣服的价格和编号(价格为第一关键字)即可. 由于每件衣服只能被买一次,因此当一件衣服被买走之后,我们可以给它打个标记表示它已…
Encoding Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 65536/32768 K (Java/Others) http://acm.hdu.edu.cn/showproblem.php?pid=1020 Problem Description Given a string containing only 'A' - 'Z', we could encode it using the following method: …
A - Pokemon Master Time Limit:2000MS Memory Limit:65536KB 64bit IO Format:%lld & %llu Submit Status Description Calem and Serena are pokemon masters. One day they decided to have a pokemon battle practice before Pokemon World Championships. Each of t…
{A} + {B} Time Limit: 10000/5000 MS (Java/Others)    Memory Limit: 65536/32768 K (Java/Others) http://acm.hdu.edu.cn/showproblem.php?pid=1412 Problem Description 给你两个集合,要求{A} + {B}. 注:同一个集合中不会有两个相同的元素.   Input 每组输入数据分为三行,第一行有两个数字n,m(0<n,m<=10000),分别…
Codeforces-566F 题目大意:给出一个有序数列a,这个数列中每两个数,如果满足一个数能整除另一个数,则这两个数中间是有一条边的,现在有这样的图,求最大联通子图. 题解:并不需要把图搞出来,可以直接dp,$f[i]$表示以第$i$个数为开头的最大的联通子图,转移类似最长上升子序列,$f[i]=max(f[i],f[j]+1)$ Code: #include<iostream> #include<cstdio> #include<algorithm> #incl…
Codeforces Round #371 (Div. 2) A. Meeting of Old Friends |B. Filya and Homework A. Meeting of Old Friends  模拟 #include <iostream> #include <cstdio> #include <algorithm> #include <cstring> using namespace std; typedef long long ll;…
ACM小白...非常费劲儿的学习中,我觉得目前我能做出来的都可以划分在水题的范围中...不断做,不断总结,随时更新 POJ: 1004 Financial Management 求平均值 杭电OJ: 1001  Sum Problem 相加1002  A + B Problem II 模拟人工加法-精度计算 1008 Elevator 很水,但是情况要考虑全面…
http://www.lydsy.com/JudgeOnline/problem.php?id=1601 很水的题,但是一开始我看成最短路了T_T 果断错. 我们想,要求连通,对,连通!连通的价值最小!当然是生成树!最小生成树! 边的还好做,但是这题有点,怎么办呢? 因为点在图中也起到连通作用,我们加个附加源,向每个点连边,价值为对应点权. ! 然后就ok了.. #include <cstdio> #include <cstring> #include <cmath>…
题意:给定两个速度,一个一初速度,一个末速度,然后给定 t 秒时间,还每秒速度最多变化多少,让你求最长距离. 析:其实这个题很水的,看一遍就知道怎么做了,很明显就是先从末速度开始算起,然后倒着推. 代码如下: #include <bits/stdc++.h> using namespace std; typedef long long LL; const int maxn = 1e5 + 5; const int INF = 0x3f3f3f3f; vector<int> ans;…
A. Link/Cut Tree 题目连接: http://www.codeforces.com/contest/614/problem/A Description Programmer Rostislav got seriously interested in the Link/Cut Tree data structure, which is based on Splay trees. Specifically, he is now studying the expose procedure…
题意:給定兩個小寫的字串a與b,請印出皆出現在兩字串中的字母,出現的字母由a~z的順序印出,若同字母出現不只一次,請重複印出但不能超過任一字串中出現的次數.(from Ruby兔) 很水,直接比较输出即可. 代码: #include <cstdio> #include <cstring> #include <algorithm> using namespace std; const int maxn = 1001; int main() { char a[maxn],…
最近转到vim上来了,用vim编写代码,用gcc编译,用gdb调试.这是用vim做的第一道题,纪念下.题目很水,就不说了. /* * Author : ben */ #include <cstdio> #include <cstdlib> #include <cstring> #include <cmath> #include <ctime> #include <iostream> #include <algorithm>…