![](https://img-blog.csdnimg.cn/20201014180756738.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
河南第十届省赛
持之以恒_fighting
人生的冷暖 取决于 自己心灵的高度
展开
-
B 情报传递 河南第十届ACM真题 【图】
/*100 1 2 1 3 0 0 3 210 Send 0Send 3Danger 2Send 7Send 5Send 9Danger 9Send 4Send 1Send 91321311101#include #include int s[5005];int head[50原创 2017-05-09 20:32:29 · 491 阅读 · 0 评论 -
H Intelligent Parking Building 河南第十届ACM真题 【模拟】
/*有一个停车楼,停车楼里的车需要全部开出去,标号为-1的位置为空,其他的数字为汽车,汽车出库必须要按照数字从小到大的顺序,停车楼出口为第一层第一个 位置,其中电梯在每一行的第一列, 每一行是一个环形传送带,每移动一格耗费5分钟,每移动一层消耗10分钟,电梯每上楼接车,到达每一层接车,然后下去从开头出口出去。 问你最少耗费多长时间所有的车都可以出去。*/题意好难,思路不难。原创 2017-05-09 20:42:07 · 584 阅读 · 0 评论 -
G Plumbing the depth of lake 河南第十届ACM真题 【搜索】
/*八个方向搜索,找到连续大于等于 两个 相同 的最深的地方。 */#include #include int map[55][55];int dx[8] = {-1,-1,-1,0,0,1,1,1};int dy[8] = {-1,0,1,-1,1,-1,0,1};int max;void search(int i,int j){ int k; if(map[i原创 2017-05-09 20:39:17 · 584 阅读 · 0 评论 -
F Binary to Prime 河南第十届ACM真题 【模拟】
/*二进制数 每位对应的 0 1 从低位到高位,0代表没有 1代表当前为有素数。素数从 2 开始。求0 1串 累加成素数的和 */ #include #include char str[160];bool vis[2000];int s[2000];using namespace std;void Prime()//筛出来 { int i,j; fo原创 2017-05-09 20:37:28 · 430 阅读 · 0 评论 -
D 年终奖金 河南第十届ACM真题 【dp】
#include #include #include using namespace std;int a[105];int dp[105];int make(int x,int y){ return (x-y)*(x-y);}int main(){ int n,k,c,i,j; while(scanf("%d%d%d",&n,&k,&c)!=EOF){ memset(d原创 2017-05-09 20:35:46 · 438 阅读 · 0 评论 -
C 最小密钥 河南第十届ACM真题 【模拟】
#include #include int s[3005];bool vis[20005];int main(){ int T; scanf("%d",&T); while(T--) { int n,i,j; scanf("%d",&n); for(i=1;i<=n;i++){ scanf("%d",&s[i]); } for(i=1;i<=20000;原创 2017-05-09 20:34:18 · 482 阅读 · 0 评论 -
A 谍报分析 河南第十届ACM真题 【字符串处理】
/*统计一篇单词,先按照数量多少排序,再按照字符串字典序排序。 */字符串每次做都是各种细节,好废时间。#include #include #include using namespace std;struct Node{ char str[25]; int cnt;}edge[10005];int cmp(Node a,Node b){ if(a.cnt原创 2017-05-09 20:29:57 · 506 阅读 · 0 评论