给 n 中 钱币.以及每两种钱币的关系,表示,ai 的 个数 要大于 bi 组合成一个价值val,求方案数,好奇妙的一个处理方式,不得不说又学到了 #include<stdio.h> #include<vector> #include<cstring> #include<iostream> using namespace std; const int mod = 1e9 + 7; const int M = 1e5 + 1; long long dp[M];…
A. Two Bags of Potatoes 枚举倍数. B. Easy Tape Programming (待补) C. Not Wool Sequences 考虑前缀异或和. \[answer = \prod_{i=1}^{n}{2^m-i}\] D. Boring Partition \(a_i\)从小到大排序,以某个\(i\)为分界点,考虑各种情况的最值,其中1.n分别为单个组时需要特殊考虑. E. World Eater Brothers 枚举根,那么需要修改的边假设为\(E\),另…
题目链接: http://codeforces.com/problemset/problem/507/E E. Breaking Good time limit per test2 secondsmemory limit per test256 megabytes 问题描述 Breaking Good is a new video game which a lot of gamers want to have. There is a certain level in the game that…
Problem A. Arrangement of Contest 题目连接: http://codeforces.com/gym/100269/attachments Description Little Dmitry and little Petr want to arrange a contest. Their little friends submitted several task proposals and now Dmitry and Petr want to select som…
The Pilots Brothers' refrigerator Time Limit: 1000MS Memory Limit: 65536K Total Submissions: 22286 Accepted: 8603 Special Judge Description The game “The Pilots Brothers: following the stripy elephant” has a quest where a player needs to open a…
http://codeforces.com/contest/738/problem/D Galya is playing one-dimensional Sea Battle on a 1 × n grid. In this game a ships are placed on the grid. Each of the ships consists of bconsecutive cells. No cell can be part of two ships, however, the shi…
http://codeforces.com/contest/738/problem/C Vasya is currently at a car rental service, and he wants to reach cinema. The film he has bought a ticket for starts in t minutes. There is a straight road of length s from the service to the cinema. Let's…