HDU6500:Problem A. Game with string 题意: 给你一个字符串s以及它的m个子串的首尾位置,现在Alice和 Bob两个人轮流在任一子串的前面或者后面加1个字符,要求加了这个串加了一个字符之后仍然是s的子串,谁不能加了谁就输了,要你输出谁赢. 题解: 每个子串可以加的字符次数是恒定的:s串的长度-子串的长度.那么我们将所有子串可以加的次数加起来再判断奇偶就能得出答案. 傻逼多组WA了几发 代码: #include <bits/stdc++.h> using na…
Coconuts Time Limit: 9000/4500 MS (Java/Others) Memory Limit: 65536/65536 K (Java/Others)Total Submission(s): 524 Accepted Submission(s): 151 Problem Description TanBig, a friend of Mr. Frog, likes eating very much, so he always has dreams abou…
Basic Data Structure Time Limit: 7000/3500 MS (Java/Others) Memory Limit: 65536/65536 K (Java/Others)Total Submission(s): 872 Accepted Submission(s): 236 Problem Description Mr. Frog learned a basic data structure recently, which is called stac…
Mr. Frog's Game Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/65536 K (Java/Others)Total Submission(s): 277 Accepted Submission(s): 192 Problem Description One day, Mr. Frog is playing Link Game (Lian Lian Kan in Chinese).In this g…
Mr. Frog's Problem Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/65536 K (Java/Others)Total Submission(s): 312 Accepted Submission(s): 219 Problem Description One day, you, a clever boy, feel bored in your math class, and then fall…
Minimum's Revenge Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/65536 K (Java/Others)Total Submission(s): 283 Accepted Submission(s): 219 Problem Description There is a graph of n vertices which are indexed from 1 to n. For any pai…
Auxiliary Set Time Limit: 9000/4500 MS (Java/Others) Memory Limit: 65536/65536 K (Java/Others)Total Submission(s): 873 Accepted Submission(s): 271 Problem Description Given a rooted tree with n vertices, some of the vertices are important.An au…