Educational Codeforces Round 5 A. Comparing Two Long Integers
You are given two very long integers a, b (leading zeroes are allowed). You should check what number a or b is greater or determine that they are equal.
The input size is very large so don't use the reading of symbols one by one. Instead of that use the reading of a whole line or token.
As input/output can reach huge size it is recommended to use fast input/output methods: for example, prefer to use scanf/printf
相關推薦
Educational Codeforces Round 5 A. Comparing Two Long Integers
You are given two very long integers a, b (leading zeroes are allowed). You should check what number a or b is greater or determine that they are equal.
Educational Codeforces Round 23 A-F 補題
als nal 枚舉 typedef code col sca 復雜 long long A Treasure Hunt 註意負數和0的特殊處理。。 水題。。 然而又被Hack了 嗎的智障 #include<bits/stdc++.h> using names
Educational Codeforces Round 21 A-E題題解
說了 else round int 排序 總量 允許 main ret A題 ............太水就不說了,貼下代碼 #include<string> #include<iostream> #include<cstring&
Educational Codeforces Round 24 A
num them have time take tin return == logs There are n students who have taken part in an olympiad. Now it‘s time to award the students.
Educational Codeforces Round 30 A[水題/數組排序]
sta getch scan line nta blog clu spl ever A. Chores time limit per test 2 seconds memory limit per test 256 megabytes input
【Educational Codeforces Round 35 A】 Nearest Minimums
oca ati n) ret 代碼 ini for txt names 【鏈接】 我是鏈接,點我呀:) 【題意】 在這裏輸入題意 【題解】 找出最小的數字的位置。 最近的肯定是相鄰的某對。 【代碼】 #include <bits/stdc++.h&
Educational Codeforces Round 37 A B C F (暫時)
n) body else if 並查集 fine namespace push swap har A. water the garden Code #include <bits/stdc++.h> #define maxn 210 using namespace
【Educational Codeforces Round 37 A】 Water The Garden
define 記錄 const log body ace test ret href 【鏈接】 我是鏈接,點我呀:) 【題意】 在這裏輸入題意 【題解】 記錄下水龍頭在哪些位置。 然後每秒鐘把index-i和index+i改變狀態一下就好(置1 【代碼】
Educational Codeforces Round 54---A.........【未完成】
sin hid str != lag stream char names i++ A---Minimizing the String 1 #include<iostream> 2 #include<cstdio> 3 #include&
coderforces Educational Codeforces Round 57 A-D
在寢室睡了幾天以後過來做 自閉了 A題 題意 給你t組樣例 一個區間 l 到 r ,讓你輸出 l 到 r 內一對其中一個是另一個的因子的答案 , 保證題目有解 於是我們直接輸出左端點 和左端點乘2 即可 保證是最小的答案 #include <cstdio> #includ
Educational Codeforces Round 5 D. Longest k-Good Segment
The array a with n integers is given. Let's call the sequence of one or more consecutive elements in a segment. Also let's call the segment k-good if i
codeforces Round #440 A Search for Pretty Integers【hash/排序】
dash hash acad pro section cif close esp small A. Search for Pretty Integers 【題目鏈接】:http://codeforces.com/contest/872/problem/A tim
2017-5-22-Train:Educational Codeforces Round 2
pla getc begin from same aps mage then url B. Queries about less or equal elements(二分) You are given two arrays of integers a and b. For
Educational Codeforces Round 24 CF 818 A-G 補題
red sync codeforce ner pro 有趣的 scanf 決心 Education 6月快要結束了 期末也過去大半了 馬上就是大三狗了 取消了小學期後20周的學期真心長, 看著各種北方的學校都放假嗨皮了,我們這個在北回歸線的學校,還在忍受酷暑。 過年的時候下
Educational Codeforces Round 37 (Rated for Div. 2)A,B,C,F
fine 暴力模擬 需要 lose sort codeforce 結構 分享圖片 線段樹 A Water The Garden 數據不大,暴力模擬下直至把每個花床都遍歷過的過程即可 1 #include <bits/stdc++.h> 2 us
Educational Codeforces Round 46 D. Yet Another Problem On a Subsequence
mod ons ++ 數列 一個數 () -- problem dot 題目大意 定義一個數列是“好的”:第一個數字a[0]為數列長度+1。 定義一個數列的子序列是“好的”:這個子序列能分割成幾個“好的”數列。 各一個數列,求“好的”子序列的數目。 解題思路 一開始想
Educational Codeforces Round 16 D. Two Arithmetic Progressions
解線性同餘方程組,且方程僅2個,另外得到的x限制在L,R區間內, 觀察一下A1K-A2L=B2-B1,便可知,通解(K,L)中會同時增大或同時減小,大可以先使得K,L大於等於0,於是之後只需要考慮讓K不斷增大且這樣得到的x在[L,R]內即可。 由x在[L,R]中,便可以求出K的範圍,然後分情況討論一下就好
A、B、C、D、Educational Codeforces Round 42 (Rated for Div. 2)
Educational Codeforces Round 42 (Rated for Div. 2) http://codeforces.com/contest/962 A:Equator 這裡需要注意一個問題,就是直接 / 2 的時候、有奇數偶數的情況、如果是奇數的話、這
Educational Codeforces Round 54 (Rated for Div. 2) A B C D E題解
這些題目挺有意思,起碼我都錯過,可能這兩天精力有點不足,腦子不太夠用??? A題連結:http://codeforces.com/contest/1076/problem/A 題意:給定一個字串,最多可以刪掉一個字元,使得字典序最小; 思路:首先跟原串比較的話,某一
Educational Codeforces Round 54 E - Vasya and a Tree 樹上:離線+dfs+樹狀陣列
題意: 給定一棵包含n個結點的樹,開始每個結點權值為0,現在有q個操作,每個操作包含 v, d, x,表示第v號結點,以及再往下(對於樹:他的孩子方向)遍歷d層,訪問到的結點權值都加上x; 輸出所有結點的權值 思路: 一下想到的就是區間更新,單點查詢,想寫個樹剖來著,感覺有點麻煩