B. Sereja and Suffixes Time Limit: 20 Sec Memory Limit: 256 MB 题目连接 http://codeforces.com/problemset/problem/368/B Description Sereja has an array a, consisting of n integers a1, a2, ..., an. The boy cannot sit and do nothing, he decided to study an…
B. Sereja ans Anagrams Time Limit: 20 Sec Memory Limit: 256 MB 题目连接 http://codeforces.com/problemset/problem/367/B Description Sereja has two sequences a and b and number p. Sequence a consists of n integers a1, a2, ..., an. Similarly, sequence b con…
#include <iostream> #include <vector> #include <algorithm> #include <string> using namespace std; int main(){ string s ; cin >>s; int m; cin >>m; vector<int> l(m),r(m); ; i < m ; ++ i ) cin >> l[i]>>…
#include <iostream> #include <vector> #include <algorithm> #include <set> using namespace std; int main(){ int n,m; cin >> n >>m; vector<int> a(n),l(m); ; i < n ; ++ i) cin >>a[i]; ; i < m; ++ i) cin &…
#include <iostream> #include <vector> #include <algorithm> using namespace std; int main(){ int n,d; cin >> n >>d; vector<int>a(n); ; i < n ; ++ i ) cin >>a[i]; int m; cin >> m; sort(a.begin(),a.end()); ;…
D. Sereja ans Anagrams time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output Sereja has two sequences a and b and number p. Sequence a consists of n integers a1, a2, ..., an. Similarly, sequence …
Codeforces Round #366 (Div. 2) A I hate that I love that I hate it水题 #I hate that I love that I hate it n = int(raw_input()) s = "" a = ["I hate that ","I love that ", "I hate it","I love it"] for i in ran…