Roman and Numbers time limit per test 4 seconds memory limit per test 512 megabytes input standard input output standard output Roman is a young mathematician, very famous in Uzhland. Unfortunately, Sereja doesn't think so. To make Sereja change his…
题目链接: http://codeforces.com/problemset/problem/401/D D. Roman and Numbers time limit per test4 secondsmemory limit per test512 megabytes 问题描述 Roman is a young mathematician, very famous in Uzhland. Unfortunately, Sereja doesn't think so. To make Sere…
D. Roman and Numbers time limit per test 4 seconds memory limit per test 512 megabytes input standard input output standard output Roman is a young mathematician, very famous in Uzhland. Unfortunately, Sereja doesn't think so. To make Sereja change h…
传送门 D. The Maths Lecture time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output Amr doesn't like Maths as he finds it really boring, so he usually sleeps in Maths lectures. But one day the teacher…
Codeforces Round #267 (Div. 2) C. George and Job题目链接请点击~ The new ITone 6 has been released recently and George got really keen to buy it. Unfortunately, he didn't have enough money, so George was going to work as a programmer. Now he faced the follow…
A. Vanya and Cards time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output Vanya loves playing. He even has a special set of cards to play with. Each card has a single integer. The number on the ca…
D. Roman Digits time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output Let's introduce a number system which is based on a roman digits. There are digits I, V, X, L which correspond to the numbers…
链接:https://codeforces.com/contest/1100/problem/A 题意: 给定n,k. 给定一串由正负1组成的数. 任选b,c = b + i*k(i为任意整数).将c所有c位置的数删除,求-1和1个数差值绝对值的最大值. 思路: 暴力遍历 代码: #include <bits/stdc++.h> using namespace std; int a[110]; int main() { int n,k; scanf("%d%d",&…
#include <iostream> #include <algorithm> using namespace std; int main(){ int n,m; cin >> n >> m; ) || m > (n + )* ) cout<< -; else if( n>= m) { ; i < m; ++ i) cout<<"; "; }>=m){ ; i< m - n; ++…