April Fools Contest 2017 C】的更多相关文章

A. Numbers Joke time limit per test:2 seconds memory limit per test:64 megabytes input:standard input output:standard output   Input The input contains a single integer a (1 ≤ a ≤ 30). Output Output a single integer. Example Input 3 Output 27 题目链接:ht…
都是神题,我一题都不会,全程听学长题解打代码,我代码巨丑就不贴了 题解见巨神博客 假装自己没有做过这套…
趁着上课无聊,来补一补-- A. Numbers Joke 直接oeis就好了:http://oeis.org/search?q=numbers+joke&language=english&go=Search #include<bits/stdc++.h> using namespace std; long long p[]={ 4, 22, 27, 58, 85, 94, 121, 166, 202, 265, 274, 319, 346, 355, 378, 382, 39…
Description You are developing a new feature for the website which sells airline tickets: being able to sort tickets by price! You have already extracted the tickets' prices, so there's just the last step to be done... You are given an array of integ…
Description Input The input consists of four lines, each line containing a single digit 0 or 1. Output Output a single digit, 0 or 1. Example input 0110 output 0 一个数字电路,不过或门和异或门是反的,所以..注意下 #include<bits/stdc++.h> using namespace std; #define ll long…
Description Input The only line of the input contains a string of digits. The length of the string is between 1 and 10, inclusive. Output Output "Yes" or "No". Examples input 373 output Yes input 121 output No input 436 output Yes看是不是回…
Description DO YOU EXPECT ME TO FIND THIS OUT? WHAT BASE AND/XOR LANGUAGE INCLUDES string? DON'T BYTE OF MORE THAN YOU CAN CHEW YOU CAN ONLY DISTORT THE LARGEST OF MATHEMATICS SO FAR SAYING "ABRACADABRA" WITHOUT A MAGIC AND WON'T DO YOU ANY GOOD…
Description Programmers' kids solve this riddle in 5-10 minutes. How fast can you do it? Input The input contains a single integer n (0 ≤ n ≤ 2000000000). Output Output a single integer. Examples input 11 output 2 input 14 output 0 input 61441 output…
Description Input The input contains a single integer a (1 ≤ a ≤ 30). Output Output a single integer. Example input 3 output 27 那个,这个,额,查题目名称吧Numbers Joke #include<bits/stdc++.h> using namespace std; #define ll long long ll a[]={,, , , , , , , , , ,…
这个比赛不正经,但是我可以一本正经的写代码啊 A. Quirky Quantifiers time limit per test 2 seconds memory limit per test 64 megabytes input standard input output standard output   Input The input contains a single integer a (10 ≤ a ≤ 999). Output Output 0 or 1. Examples inp…
April Fools Day Contest 2014 A.C.H三道题目 =================================================================== A. The Great Game 这题怎没看懂..看了官方题解真是恍然大悟啊,原来是石头剪刀布啊!!! 8< 代表剪刀啊 () 代表石头啊 [] 代表布啊 真是逆天啊,这么一说还真觉得有点像....尤其是那个剪刀. 给那个出题人的想象力跪了. /* * ===============…
H - A + B Strikes Back A + B is often used as an example of the easiest problem possible to show some contest platform. However, some scientists have observed that sometimes this problem is not so easy to get accepted. Want to try? Input The input co…
H. A + B Strikes Back time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output A + B is often used as an example of the easiest problem possible to show some contest platform. However, some scientis…
NAIPC 2017 Yin and Yang Stones 75.39% 1000ms 262144K   A mysterious circular arrangement of black stones and white stones has appeared. Ming has been tasked with balancing the stones so that only one black and one white stone remain. Ming has two ope…
1065 Beihang Collegiate Pronunciation Contest 2017 思路 在字符串中不断做匹配 找到一个匹配就输出 时间复杂度\(O(n)\) ps.模式串是定长的,因此看做常数 代码 #include<string> #include<iostream> using namespace std; int main() { int n; cin >> n; string ch; cin >> ch; for (auto i…
G. Fake News (easy) time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output As it's the first of April, Heidi is suspecting that the news she reads today are fake, and she does not want to look sil…
ACM International Collegiate Programming Contest, Tishreen Collegiate Programming Contest (2017)- K. Poor Ramzi -dp+记忆化搜索 [Problem Description] 给你一串\(01\)字符串,将其划分,使得划分后,分别求出每组\(01\)之和后是回文的,求划分的方案数, [Solution] 定义\(dp[l][r]\)表示,区间\([l,r]\)中满足条件的方案数是多少.…
D. Rosetta Problem 题目连接: http://www.codeforces.com/contest/656/problem/D Description ++++++++[>+>++>+++>++++>+++++>++++++>+++++++>++++++++>+++++++++>++++++++++>+ ++++++++++>++++++++++++>+++++++++++++>+++++++++++++…
G. You're a Professional 题目连接: http://www.codeforces.com/contest/656/problem/G Description A simple recommendation system would recommend a user things liked by a certain number of their friends. In this problem you will implement part of such a syst…
F. Ace It! 题目连接: http://www.codeforces.com/contest/656/problem/F Description Input The only line of the input is a string of 7 characters. The first character is letter A, followed by 6 digits. The input is guaranteed to be valid (for certain definit…
E. Out of Controls 题目连接: http://www.codeforces.com/contest/656/problem/E Description You are given a complete undirected graph. For each pair of vertices you are given the length of the edge that connects them. Find the shortest paths between each pa…
C. Without Text 题目连接: http://www.codeforces.com/contest/656/problem/C Description You can preview the image in better quality by the link: http://assets.codeforces.com/files/656/without-text.png Input The only line of the input is a string (between 1…
B. Scrambled 题目连接: http://www.codeforces.com/contest/656/problem/B Description Btoh yuo adn yuor roomatme lhoate wianshg disehs, btu stlil sdmoeboy msut peorrfm tihs cohre dialy. Oen dya yuo decdie to idourtcne smoe syestm. Yuor rmmotaoe sstgegus teh…
A. Da Vinci Powers 题目连接: http://www.codeforces.com/contest/656/problem/A Description The input contains a single integer a (0 ≤ a ≤ 35). Input Output a single integer. Output In the first line print "YES" (without quotes), if Polycarpus can perf…
题目连接:http://codeforces.com/problemset/problem/656/E 愚人节专场的E,整个其实就是个Floyd算法,但是要求代码中不能包含 definedoforforeachwhilerepeatuntilifthenelseelifelsifelseifcaseswitch 这些关键词. 如果不考虑屏蔽define,很容易想到将代码中用到的关键词全部define成其它不在列表中的词.但是define的时候还是得要写出原来的关键词,况且define也被屏蔽了,…
A. Thanos Sort time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output Thanos sort is a supervillain sorting algorithm, which works as follows: if the array is not sorted, snap your fingers* to rem…
A. Thanos Sort time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output Thanos sort is a supervillain sorting algorithm, which works as follows: if the array is not sorted, snap your fingers* to rem…
Description The marmots have prepared a very easy problem for this year's HC2 – this one. It involves numbers n, k and a sequence of n positive integersa1, a2, ..., an. They also came up with a beautiful and riveting story for the problem statement.…
http://codeforces.com/contest/802/problem/N [题解] 方法一: #include<bits/stdc++.h> using namespace std; typedef long long LL; #define N 200020 int to[N], head[N], nxt[N], cost[N], cap[N], cnt; , sizeof head); } void add_Edge(int S, int T, int c, int w){…
Problem A : Electric Bill 题目大意:进行电量分级制收费,1000kwh及以下一档收费,1000kwh以上按另一档收费,给出每个人的电量总额,问每人应支付多少钱. 思路:基础if else题,对于每个电量判断是否大于1000,再分别计算≤1000的价格和>1000的价格,最后相加并输出. #include<algorithm> #include<iostream> #include<cstring> #include<cstdio&g…