hdoj
ZONE画派
正在学习计算机视觉相关
展开
-
20140715 「博弈 - NP问题」 HDOJ 2147
#include using namespace std;int main(){ freopen("kiki.in","r",stdin); int a, b; while( ~scanf("%d%d", &a, &b) && a && b ){ if( a&1 && b&1 ) printf("What a pity!\n"); else原创 2014-07-15 17:34:52 · 914 阅读 · 0 评论 -
20140912 【 拓扑排序 】 bestcoder #1+hdoj 4857 逃生
#include #include #include #include using namespace std;#define MAXN 30010vector v[MAXN];int n, m, cnt[MAXN], ans[MAXN];int main(){ int T, x, y, counter; while( EOF != scanf("%d", &T)原创 2014-09-12 21:18:20 · 1054 阅读 · 0 评论 -
20140916 【 STL - 暴力 】 bestcoder #1 + hdoj 4858 项目管理
#include #include #include #include #include #include #include using namespace std;#define MAXN 100010typedef long long LL;vector v[MAXN];int n, m;LL sum[MAXN];int main(){ int原创 2014-09-16 14:06:59 · 791 阅读 · 0 评论 -
20140916 【 贪心 】 bestcoder #2 + hdoj 4883 TIANKENG’s restaurant
#include #include #include using namespace std;#define MAXN 10100#define MIN 0struct PP{ int n, t;}a[MAXN*2];bool cmp(const PP a, const PP b){ return a.t<b.t; }int n;int main(){原创 2014-09-16 16:00:30 · 844 阅读 · 0 评论 -
20141006 【 STL 】 bestcoder #12 So easy
Online JudgeOnline ExerciseOnline TeachingOnline ContestsExercise AuthorF.A.QHand In HandOnline AcmersForum | DiscussStatistical ChartsProblem ArchiveRealtime Judge Statu原创 2014-10-06 10:42:38 · 635 阅读 · 0 评论 -
20140929 【 树状数组 】 BestCoder Round #11 (Div. 2) Argestes and Sequence
HomeContestsNotificationClarificationProblemsRanklistStatusHackStatus题目已经添加到OJ题库末尾,题解放在了首页More...Argestes and SequenceTime Limit: 5000/2500 MS (Java/Others) Memory原创 2014-09-29 12:06:26 · 540 阅读 · 0 评论 -
20141002 【 单调队列 】 hdoj 3530 Subsequence
Online JudgeOnline ExerciseOnline TeachingOnline ContestsExercise AuthorF.A.QHand In HandOnline AcmersForum | DiscussStatistical ChartsProblem ArchiveRealtime Judge Statu原创 2014-10-02 10:40:49 · 663 阅读 · 0 评论 -
20140930 【 DP - 状态压缩 】 2014-上海区域赛-网络预选赛 hdoj 5045 Contest
Online JudgeOnline ExerciseOnline TeachingOnline ContestsExercise AuthorF.A.QHand In HandOnline AcmersForum | DiscussStatistical ChartsProblem ArchiveRealtime Judge Statu原创 2014-09-30 13:38:22 · 641 阅读 · 0 评论 -
20140930 【 数论 -- 本福特定律 】 2014-上海区域赛-网络预选赛 hdoj 5051 Fraction
Online JudgeOnline ExerciseOnline TeachingOnline ContestsExercise AuthorF.A.QHand In HandOnline AcmersForum | DiscussStatistical ChartsProblem ArchiveRealtime Judge Statu原创 2014-09-30 17:34:39 · 1164 阅读 · 0 评论 -
20141001 【 高精度 】 2014-上海区域赛-网络预选赛 hdoj 5047 Sawtooth
Online JudgeOnline ExerciseOnline TeachingOnline ContestsExercise AuthorF.A.QHand In HandOnline AcmersForum | DiscussStatistical ChartsProblem ArchiveRealtime Judge Statu原创 2014-10-01 10:07:56 · 693 阅读 · 0 评论 -
20141001 【 高精度 】 hdoj 2054 A == B ?
Online JudgeOnline ExerciseOnline TeachingOnline ContestsExercise AuthorF.A.QHand In HandOnline AcmersForum | DiscussStatistical ChartsProblem ArchiveRealtime Judge Statu原创 2014-10-01 16:14:11 · 675 阅读 · 0 评论 -
20141001 【 高精度?/数论--斐波那契数列 】 hdoj 1568 Fibonacci
Online JudgeOnline ExerciseOnline TeachingOnline ContestsExercise AuthorF.A.QHand In HandOnline AcmersForum | DiscussStatistical ChartsProblem ArchiveRealtime J原创 2014-10-01 17:55:30 · 1685 阅读 · 0 评论 -
20140920 【 线段树 — 区间覆盖,区间查询 】 2014 ACM/ICPC Asia Regional Guangzhou Online--A Corrupt Mayor's Perfor
Online JudgeOnline ExerciseOnline TeachingOnline ContestsExercise AuthorF.A.QHand In HandOnline AcmersForum | DiscussStatistical ChartsProblem ArchiveRealtime Judge Statu原创 2014-09-20 17:43:36 · 1697 阅读 · 0 评论 -
20140715 「博弈 - Nim(尼姆)博弈」 HDOJ 1907 John
博弈:尼姆博弈 模板一份题解嘛,有空再补。。。#include #define MAXN 4888int main(){ //freopen("John.in","r",stdin); int a[MAXN], T, n; while( ~scanf("%d", &T) ){ while( T-- && ~scanf(原创 2014-07-15 17:42:01 · 559 阅读 · 0 评论 -
20140715 「博弈 - 巴什博弈」 HDOJ 1846 Brave Game
#include int main(){ int T, n, m; scanf("%d", &T); while( T-- && ~scanf("%d%d", &n, &m) ){ printf("%s\n", (n%(m+1)) ? "first" : "second"); } return 0;}原创 2014-07-15 17:34:29 · 554 阅读 · 0 评论 -
20140723 【字典树 - 前缀树,指针版】 HDOJ 1251 统计难题
Online JudgeOnline ExerciseOnline TeachingOnline ContestsExercise AuthorF.A.QHand In HandOnline AcmersForum | DiscussStatistical ChartsProblem ArchiveRealtime Judge Statu原创 2014-07-23 11:00:17 · 638 阅读 · 0 评论 -
20140719 「线段树 - 区间替换,区间求和」 HDOJ 1698 Just a Hook
Online JudgeOnline ExerciseOnline TeachingOnline ContestsExercise AuthorF.A.QHand In HandOnline AcmersForum | DiscussStatistical ChartsProblem ArchiveRealtime Judge Statu原创 2014-07-19 13:21:58 · 656 阅读 · 0 评论 -
20140725 【 并查集 】 HDOJ 1198 Farm Irrigation
#include #include using namespace std;#define bit(i,j) ((i-1)*c+j)#define MAXN 55const int pipe[11] = {9,3,12,6,5,10,11,13,14,7,15};int maps[MAXN][MAXN], r, c;int par[MAXN*MAXN];char ch;int原创 2014-07-25 20:17:31 · 845 阅读 · 0 评论 -
20140723 【字典树 - 前缀树,数组模拟指针】 HDOJ 1305 Immediate Decodability
Online JudgeOnline ExerciseOnline TeachingOnline ContestsExercise AuthorF.A.QHand In HandOnline AcmersForum | DiscussStatistical ChartsProblem ArchiveRealtime Judge Statu原创 2014-07-23 13:58:52 · 719 阅读 · 0 评论 -
20140719 「线段树 - 点替换,区间最值」 HDOJ 1754 I Hate It
Online JudgeOnline ExerciseOnline TeachingOnline ContestsExercise AuthorF.A.QHand In HandOnline AcmersForum | DiscussStatistical ChartsProblem ArchiveRealtime Judge Statu原创 2014-07-19 10:50:47 · 582 阅读 · 0 评论 -
20140715 「博弈 - Nim(尼姆)博弈」 HDOJ 1850 Being a Good Boy in Spring Festival
博弈:尼姆博弈 模板一题解嘛,有空再补。。。#include int main(){ int n, a[105]; while( ~scanf("%d", &n) && n ){ int sum = 0, ans = 0; for(int i=0; i<n; i++){ scanf("%d", &a[i]); sum ^=原创 2014-07-15 17:37:13 · 563 阅读 · 0 评论 -
20140715 「博弈 - 巴什博弈」 HDOJ 2149 Public Sale
#include int main(){ int m, n; while( ~scanf("%d%d", &m, &n) ){ int ans = m%(n+1); if( ans ){ if( n<m ) n = ans; for(int i=ans; i<=n; i++) printf("%d%c", i, i==n?'\n':' ');原创 2014-07-15 17:25:24 · 613 阅读 · 0 评论 -
20140715 「博弈 - 巴什博弈」 HDOJ 2188 悼念512汶川大地震遇难同胞——选拔志愿者
#include int main(){ int T, n, m; while( ~scanf("%d", &T) ){ while( T-- && ~scanf("%d%d", &n, &m) ){ printf("%s\n", n%(m+1) ? "Grass":"Rabbit"); } } return 0;}原创 2014-07-15 17:28:45 · 557 阅读 · 0 评论 -
20140715 「博弈 - 威佐夫博弈」 HDOJ 1527 取石子游戏
#include int main(){ int a, b; while( ~scanf("%d%d", &a, &b) ){ if( a>b ) { int tmp=a; a=b; b=tmp; } long k = b-a; printf("%d\n", !( a==(int)(1.618033989*k) ) ); } return 0;}原创 2014-07-15 18:02:13 · 755 阅读 · 0 评论 -
20140715 「博弈 - Nim(尼姆)博弈」 HDOJ 2509 Be the Winner
#include #define MAXN 111int main(){ //freopen("Be.in","r",stdin); int a[MAXN], n; while( EOF != scanf("%d", &n) ){ int sum = 0, ans = 0; for(int i=0; i<n; i++){ scanf("%d", &a[i]);原创 2014-07-15 17:41:37 · 689 阅读 · 0 评论 -
20141002 【 数论--概率 】 hdoj 5035 Delivery
Online JudgeOnline ExerciseOnline TeachingOnline ContestsExercise AuthorF.A.QHand In HandOnline AcmersForum | DiscussStatistical ChartsProblem ArchiveRealtime Judge Statu原创 2014-10-02 11:55:15 · 697 阅读 · 0 评论