Description You are given n strings s1, s2, ..., sn consisting of characters 0 and 1. m operations are performed, on each of them you concatenate two existing strings into a new one. On the i-th operation the concatenation saisbi is saved into a new…
You are given n strings s1, s2, ..., sn consisting of characters 0 and 1. m operations are performed, on each of them you concatenate two existing strings into a new one. On the i-th operation the concatenation saisbi is saved into a new string sn + …
B. Strings of Power Time Limit: 20 Sec Memory Limit: 256 MB 题目连接 http://codeforces.com/contest/318/problem/B Description Volodya likes listening to heavy metal and (occasionally) reading. No wonder Volodya is especially interested in texts concerning…
A. Bark to Unlock 题目链接:http://codeforces.com/contest/868/problem/A 题目意思:密码是两个字符组成的,现在你有n个由两个字符组成的字符串,现在问是否可以用你手上的这些字符串通过拼接其中两个的基础上使得密码是这个拼接而成的字符串的子串,一个字符串可以使用多次,这意味这自己拼接自己也是可以的. 题目思路:暴力枚举这个过程,因为总共就n最大也就100 代码: /* *************************************…
Description Have you ever tried to explain to the coordinator, why it is eight hours to the contest and not a single problem has been prepared yet? Misha had. And this time he has a really strong excuse: he faced a space-time paradox! Space and time…
Description Snark and Philip are preparing the problemset for the upcoming pre-qualification round for semi-quarter-finals. They have a bank of n problems, and they want to select any non-empty subset of it as a problemset. k experienced teams are pa…
C. Qualification Rounds time limit per test 2 seconds memory limit per test 256 megabytes input standard input output standard output Snark and Philip are preparing the problemset for the upcoming pre-qualification round for semi-quarter-finals. They…
最近只想喊666,因为我是真得菜,大晚上到网吧打代码还是很不错的嘛 A. Bark to Unlock time limit per test 2 seconds memory limit per test 256 megabytes input standard input output standard output As technologies develop, manufacturers are making the process of unlocking a phone as us…
题意: 思路: Codeforces Round #370(Solved: 4 out of 5) A - Memory and Crow 题意:有一个序列,然后对每一个进行ai = bi - bi + 1 + bi + 2 - bi + 3.... 的操作,最后得到了a 序列,给定 a 序列,求原序列. 思路:水. #include <set> #include <map> #include <stack> #include <queue> #includ…
Codeforces Educational Codeforces Round 44 (Rated for Div. 2) F. Isomorphic Strings 题目连接: http://codeforces.com/contest/985/problem/F Description You are given a string s of length n consisting of lowercase English letters. For two given strings s an…
A. Watching a movie time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output You have decided to watch the best moments of some movie. There are two buttons on your player: Watch the current minute…
Codeforces Round #270 1003 C. Design Tutorial: Make It Nondeterministic time limit per test 2 seconds memory limit per test 256 megabytes input standard input output standard output A way to make a new task is to make it nondeterministic or probabili…