
模拟
永远热血沸腾
这个作者很懒,什么都没留下…
展开
-
zoj 1016 Parencodings
比较麻烦原创 2015-01-31 19:12:43 · 408 阅读 · 0 评论 -
Codeforces Round #442 (Div. 2) C. Slava and tanks 【找规律】
分成三组 第一组是2 4 6 … 第二组是1 3 5 … 第三组是2 4 6 …#include <stdio.h>#include <string.h>#include <iostream>#include <algorithm>#include <vector>#include <queue>#include <set>#include <map>#include <st原创 2017-11-06 13:46:36 · 296 阅读 · 0 评论 -
Codeforces Round #441 (Div. 2, by Moscow Team Olympiad) D. Sorting the Coins【规律】
题目比较难读懂,读懂之后就好写了,看一下第二组样例就可以找到规律。/* ***********************************************Author :xiang578Email :i@xiang578.comCreated Time :Wed Nov 8 15:53:46 2017File Name :cf876d.c原创 2017-11-08 18:45:31 · 290 阅读 · 0 评论 -
2017年团体程序设计天梯赛-总决赛 L2-2. 重排链表
输入的数据可能不是一张链表的,陈越教授风格#include<bits/stdc++.h>using namespace std;struct node{ int add; int d; int next;} p[123456],p1[123456];int k,st,n,nt,m[123456],r[123456];int main(){ int a,d,t原创 2017-04-16 10:29:34 · 1369 阅读 · 0 评论 -
2017年团体程序设计天梯赛-总决赛 L1-6. 整除光棍
L1-6. 整除光棍当时想用java写,不过忘记Scanner怎么用了,现在用模拟重新写了一下#include<bits/stdc++.h>using namespace std;int x;int get(int c){ int k=0; for(int i=1;i<=c;i++) { k=k*10+1; k%=x; }原创 2017-04-16 10:21:16 · 1304 阅读 · 0 评论 -
ZOJ3952 Fibonacci Sequence Chicken Edition 【模拟】
#include<bits/stdc++.h>using namespace std;void print(int n){ for(int i=0; i<n; i++) { printf("c"); } printf("\n");}int main(){ int a[100]; int x=38; int y=5;原创 2017-04-10 10:13:15 · 737 阅读 · 0 评论 -
Intel Code Challenge Final Round C. Ray Tracing【模拟】
#include<bits/stdc++.h>using namespace std;typedef long long ll;const ll inf=1e15;const int N=1e6+10;struct date{ int x,y,to; ll t;} p[N];int n,m,k,d,x,y;map<pair<int,int>,int>mp;int ma原创 2016-10-11 08:14:34 · 342 阅读 · 0 评论 -
bnu52308 We don't wanna work! 【模拟+set】
#include<bits/stdc++.h>using namespace std;typedef long long ll;const int N=1e5+10;int n,m;struct node{ int num,id; string name;}p[N];int cmp(node a,node b){ if(a.num==b.num) return原创 2016-10-08 22:34:51 · 302 阅读 · 0 评论 -
IndiaHacks 2016 - Online Edition (Div. 1 + Div. 2) C. Bear and Up-Down【模拟】
/* ***********************************************Author :MaltubEmail :xiang578@foxmail.comBlog :htttp://www.xiang578.top************************************************ */#原创 2016-05-21 18:06:50 · 475 阅读 · 0 评论 -
Codeforces Round #350 (Div. 2) E. Correct Bracket Sequence Editor【模拟+链表】
#include<stdio.h>#include<string.h>#include<algorithm>#include<iostream>#include<stack>using namespace std;const int N=500000+10;struct node{ int from,next,to;}p[N];char s[N],c[N];int mai原创 2016-05-20 20:05:19 · 453 阅读 · 0 评论 -
hdu5676 ztr loves lucky numbers 【打表】
学习打表的方式,刚开始自己固定7和4的个数打表,会有很多重复效率不高,应该用dfs从1个到9个去枚举7和4。最大有一个答案是要超过long long 的所以要特判一下/* ***********************************************Author :MaltubEmail :xiang578@foxmail.comBlog原创 2016-05-01 14:12:01 · 509 阅读 · 0 评论 -
zoj3705 Applications 【简单模拟】
#include<bits/stdc++.h>using namespace std;const double eps=1e-6;struct node{ string name; double pts;}p[1024];double a[10000];int b[1000];int isprime(int x){ if(x==1) return 0;原创 2016-04-13 12:50:27 · 574 阅读 · 1 评论 -
hdu 4431 Mahjong 模拟
。。。原创 2015-10-07 18:08:15 · 343 阅读 · 0 评论 -
00-自测5. Shuffling Machine (20)
模拟原创 2015-05-09 13:36:05 · 717 阅读 · 0 评论 -
zoj 3775
。。。原创 2015-03-09 21:13:16 · 421 阅读 · 0 评论 -
uva 10057 A mid-summer night's dreamk
。。。原创 2015-02-09 16:01:17 · 424 阅读 · 0 评论 -
Codeforces Round #444 (Div. 2) C. Solution for Cube【模拟】
学习一波网上简单的思路,直接判断旋转好的情况,一共六种情况。 判最后结果时至少需要四个面。/* ***********************************************Author :xiang578Email :i@xiang578.comCreated Time :Mon Nov 6 16:11:14 2017File Name原创 2017-11-06 16:36:58 · 312 阅读 · 0 评论