So in the end we match all multipliers of a prime not yet matched and if we must discard a number we know that number will not be a waste. If n ≤ k < m, the optimal (x, y) can only be {x = 1, y = k + 1}. data ... Finding satisfactory solutions . Let fk(x) be the count of number i where Y0&X0 = X0 and X1 = Y1 (they are defined below). ps. 25A codeforces - IQ Test http://codeforces.com/problemset/problem/25/A Solution in C++ #include using namespace std; bool vow(char x) {... 112A Codeforces - Petya and strings Solution in c++ #include using namespace std; string a,b... 522B codeforces - Vanya and Books Link ; http://codeforces.com/problemset/problem/552/B Solution in C++ #include &... 723D Codeforces - Lakes in Berland Link: http://codeforces.com/problemset/problem/723/D Solution in c++ #include #include