#P339A. Helpful Maths Description Xenia the beginner mathematician is a third year student at elementary school. She is now learning the addition operation. The teacher has written down the sum of multiple numb
Helpful Maths,B. Xenia and Ringroad A. Helpful Maths 题目链接: codeforces 339A 题意: 给个字符串,要求将其中的数字从小到大排序 题解: 简单模拟 B. Xenia and Ringroad 题目链接:codeforces 339B 题意: 输入 n和m ,第 i 个点的任务只能在 ai 的......
The teacher has written down the sum of multiple numbers. Pupils should calculate the sum. To make the calculation easier, the sum only contains numbers 1, 2 and 3. Still, that isn't enough for Xenia. She is only beginning to count, so she can calculate a sum only if the summands f...
Codeforces Round #197 (Div. 2) A. Helpful Maths bfsof 一只退役蒟蒻ACMer(考研备考) 来自专栏 · Codeforces题解 创作声明: 内容包含剧透 水题 #include <bits/stdc++.h> using namespace std; typedef long long ll; int main() { ll arr[1000],a=0; string s; cin>>s; for(ll i=0;i='0...
input 1+1+3+1+3 1. output 1+1+1+3+3 1. input 2 1. output 2 1. 这种题目由于keyword少,所以就能够转换为counting sort的思想去解决。这样时间效率就仅仅有O(n)了。 void HelpfulMaths() { int A[4] = {0}; int a; while (scanf("%d", &a) != EOF) ...
codeforces水题100道 第二十五题 Codeforces Round #197 A. Helpful Maths (Div. 2) (strings) 题目链接:http://www.codeforces.com/problemset/problem/339/A 题意:重新组合加法字符串,使得按照1,2,3的顺序进行排列。 C++代码: C++
codeforces 339A.Helpful Maths B.Xenia and Ringroad 两水题,A.题意就是把字符串里面的数字按增序排列,直接上代码。#include#include#includ
[ An Ac a Day ^_^ ] CodeForces 339A Helpful Maths 熄灯了才想起来没写博客 赶紧水一道题碎觉…… 1#include<stdio.h>2#include<iostream>3#include<algorithm>4#include<math.h>5#include<string.h>6#include<string>7#include8#include<set>9#include<vector>10#include<queue>11#defineM(a,b) ...
A. Helpful Maths time limit per test 2 seconds memory limit per test 256 megabytes input standard input output standard output Xenia the beginner mathematician is a third year student at elementary school. She is now learning the addition operation. ...
Codeforces Round #197 (Div. 2) A. Helpful Maths【字符串/给一个连加计算式,只包含数字 1、2、3,要求重新排序,使得连加的数字从小到大】,A.HelpfulMathstimelimitpertest2secondsmemorylimitpertest256megabytesinputstandardinputoutputstandardoutputXeniathebeginn