Codeforces Round 764 (Div. 3)

Solutions are presented as using the least memory and the fastest execution time. It also takes the top 10 most recent solutions from each language. If you want to limit to a specific index, click the "Solved" button and go to that problem.

ContestId
Name
Phase
Frozen
Duration (Seconds)
Relative Time
Start Time
1624 Codeforces Round 764 (Div. 3) FINISHED False 8100 89997899 Jan. 10, 2022, 2:35 p.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 37404 ) B Make AP PROGRAMMING implementation math

B'Polycarp has 3 positive integers a , b and c . He can perform the following operation exactly once. Can Polycarp make it so that after performing the operation, the sequence of three numbers a , b , c (in this order) forms an arithmetic progression? Note that you cannot change the order of a , b and c . Formally, a sequence x_1, x_2, ... , x_n is called an arithmetic progression (AP) if there exists a number d (called "common difference") such that x_{i+1}=x_i+d for all i from 1 to n-1 . In this problem, n=3 . For example, the following sequences are AP: [5, 10, 15] , [3, 2, 1] , [1, 1, 1] , and [13, 10, 7] . The following sequences are not AP: [1, 2, 4] , [0, 1, 0] and [1, 3, 2] . You need to answer t independent test cases. The first line contains the number t ( 1 <= t <= 10^4 ) -- the number of test cases. Each of the following t lines contains 3 integers a , b , c ( 1 <= a, b, c <= 10^8 ). For each test case print "YES" (without quotes) if Polycarp can choose a positive integer m and multiply exactly one of the integers a , b or c by m to make [a, b, c] be an arithmetic progression. Print "NO" (without quotes) otherwise. You can print YES and NO in any (upper or lower) case (for example, the strings yEs, yes, Yes and YES will be recognized as a positive answer). In the first and second test cases, you can choose the number m=4 and multiply the second number ( b=5 ) by 4 . In the first test case the resulting sequence will be [10, 20, 30] . This is an AP with a difference d=10 . In the second test case the resulting sequence will be [30, 20, 10] . This is an AP with a difference d=-10 . In the third test case, you can choose m=1 and multiply any number by 1 . The resulting sequence will be $$'...

Tutorials

Codeforces Round #764 (Div. 3) Editorial

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
142316433 ssvb B Jan. 11, 2022, 2 a.m. OK D TESTS 19 31 1945600
142298692 swayingdream B Jan. 10, 2022, 6:11 p.m. OK GNU C11 TESTS 15 15 0
142320574 MallaSailesh B Jan. 11, 2022, 3:39 a.m. OK GNU C11 TESTS 19 15 0
142292040 Cashewnut_ggr B Jan. 10, 2022, 5:08 p.m. OK GNU C11 TESTS 2 46 0
142294301 yfzxxf B Jan. 10, 2022, 5:26 p.m. OK GNU C11 TESTS 5 46 0
142290570 amina_2155 B Jan. 10, 2022, 4:59 p.m. OK GNU C11 TESTS 2 46 0
142318880 debasishpanigrahi200 B Jan. 11, 2022, 3:04 a.m. OK GNU C11 TESTS 19 46 0
142323211 Powderqwq B Jan. 11, 2022, 4:28 a.m. OK GNU C11 TESTS 19 46 0
142295957 yfzxxf B Jan. 10, 2022, 5:42 p.m. OK GNU C11 TESTS 5 46 0
142288861 sree205 B Jan. 10, 2022, 4:51 p.m. OK GNU C11 TESTS 2 46 0
142291558 itsme_yunesh B Jan. 10, 2022, 5:05 p.m. OK GNU C11 TESTS 2 46 0
142289966 Baba_Oruch B Jan. 10, 2022, 4:55 p.m. OK GNU C++14 TESTS 2 0 0
142289696 advayaggarwal B Jan. 10, 2022, 4:54 p.m. OK GNU C++14 TESTS 2 0 0
142287226 karthik1999rocks B Jan. 10, 2022, 4:48 p.m. OK GNU C++14 TESTS 2 0 0
142295048 omarabdo2003 B Jan. 10, 2022, 5:33 p.m. OK GNU C++14 TESTS 5 0 0
142293314 rahulwadhwa157 B Jan. 10, 2022, 5:18 p.m. OK GNU C++14 TESTS 5 0 0
142291737 ground_zero B Jan. 10, 2022, 5:06 p.m. OK GNU C++14 TESTS 2 0 0
142330145 saddy_sama B Jan. 11, 2022, 5:58 a.m. OK GNU C++14 TESTS 19 15 0
142328603 karthikshenoy2001 B Jan. 11, 2022, 5:43 a.m. OK GNU C++14 TESTS 19 15 0
142328882 xiaoqi_1 B Jan. 11, 2022, 5:45 a.m. OK GNU C++14 TESTS 19 15 0
142329341 forest B Jan. 11, 2022, 5:50 a.m. OK GNU C++14 TESTS 19 15 0
142295567 5alas B Jan. 10, 2022, 5:38 p.m. OK GNU C++17 TESTS 5 0 0
142294676 dreamer2 B Jan. 10, 2022, 5:29 p.m. OK GNU C++17 TESTS 5 0 0
142294658 soolabettu B Jan. 10, 2022, 5:29 p.m. OK GNU C++17 TESTS 5 0 0
142293190 ashish_2409 B Jan. 10, 2022, 5:17 p.m. OK GNU C++17 TESTS 5 0 0
142291302 johnalejandrog.g4 B Jan. 10, 2022, 5:03 p.m. OK GNU C++17 TESTS 2 0 0
142291203 THESUNSPOT_2 B Jan. 10, 2022, 5:03 p.m. OK GNU C++17 TESTS 2 0 0
142291141 _Luci_fer B Jan. 10, 2022, 5:02 p.m. OK GNU C++17 TESTS 2 0 0
142290928 coder_arpit_k B Jan. 10, 2022, 5:01 p.m. OK GNU C++17 TESTS 2 0 0
142290659 venom150 B Jan. 10, 2022, 5 p.m. OK GNU C++17 TESTS 2 0 0
142286936 nishith27 B Jan. 10, 2022, 4:47 p.m. OK GNU C++17 TESTS 2 0 0
142291597 AceKing B Jan. 10, 2022, 5:05 p.m. OK GNU C++17 (64) TESTS 2 0 0
142290964 lucifer_15 B Jan. 10, 2022, 5:01 p.m. OK GNU C++17 (64) TESTS 2 0 0
142290305 sm_shivam B Jan. 10, 2022, 4:57 p.m. OK GNU C++17 (64) TESTS 2 0 0
142294764 divyansh_sahu B Jan. 10, 2022, 5:30 p.m. OK GNU C++17 (64) TESTS 5 0 0
142292875 opPO B Jan. 10, 2022, 5:14 p.m. OK GNU C++17 (64) TESTS 5 0 0
142292027 mashed_aloo B Jan. 10, 2022, 5:08 p.m. OK GNU C++17 (64) TESTS 2 0 0
142325127 alif_cse_ju B Jan. 11, 2022, 5 a.m. OK GNU C++17 (64) TESTS 19 15 0
142324116 HP_BenLadeN B Jan. 11, 2022, 4:44 a.m. OK GNU C++17 (64) TESTS 19 15 0
142323091 vineetwidhani01 B Jan. 11, 2022, 4:26 a.m. OK GNU C++17 (64) TESTS 19 15 0
142327913 yaoweiliu B Jan. 11, 2022, 5:35 a.m. OK GNU C++17 (64) TESTS 19 15 0
142292949 7oSkaaa B Jan. 10, 2022, 5:15 p.m. OK GNU C++20 (64) TESTS 5 0 0
142292243 Alaafathhyy B Jan. 10, 2022, 5:10 p.m. OK GNU C++20 (64) TESTS 2 0 0
142292166 D.t.R B Jan. 10, 2022, 5:09 p.m. OK GNU C++20 (64) TESTS 2 0 0
142293366 ld10 B Jan. 10, 2022, 5:18 p.m. OK GNU C++20 (64) TESTS 5 0 0
142293433 spydermonk B Jan. 10, 2022, 5:19 p.m. OK GNU C++20 (64) TESTS 5 0 0
142293768 36__PAIN__48 B Jan. 10, 2022, 5:22 p.m. OK GNU C++20 (64) TESTS 5 0 0
142294214 laren B Jan. 10, 2022, 5:25 p.m. OK GNU C++20 (64) TESTS 5 0 0
142294503 NajemAldeen B Jan. 10, 2022, 5:27 p.m. OK GNU C++20 (64) TESTS 5 0 0
142295884 manideep1821 B Jan. 10, 2022, 5:41 p.m. OK GNU C++20 (64) TESTS 5 0 0
142292330 ANON7MOUS B Jan. 10, 2022, 5:10 p.m. OK GNU C++20 (64) TESTS 2 0 0
142289762 pieterfsnyman B Jan. 10, 2022, 4:54 p.m. OK Go TESTS 2 46 512000
142290194 tovenja B Jan. 10, 2022, 4:57 p.m. OK Go TESTS 2 46 1228800
142310618 1e9y B Jan. 10, 2022, 9:46 p.m. OK Go TESTS 19 61 1126400
142310632 1e9y B Jan. 10, 2022, 9:46 p.m. OK Go TESTS 19 62 1126400
142312855 TomazGomes B Jan. 10, 2022, 11:24 p.m. OK Haskell TESTS 19 109 0
142290819 pen_flex B Jan. 10, 2022, 5:01 p.m. OK Java 11 TESTS 2 155 0
142291320 LongWalk B Jan. 10, 2022, 5:04 p.m. OK Java 11 TESTS 2 156 0
142290966 podtelkin B Jan. 10, 2022, 5:01 p.m. OK Java 11 TESTS 2 170 0
142291419 SaberXpro B Jan. 10, 2022, 5:04 p.m. OK Java 11 TESTS 2 171 0
142329088 iamsoumik B Jan. 11, 2022, 5:48 a.m. OK Java 11 TESTS 19 171 0
142305198 skhammad B Jan. 10, 2022, 7:39 p.m. OK Java 11 TESTS 15 186 0
142290388 Robertino B Jan. 10, 2022, 4:58 p.m. OK Java 11 TESTS 2 186 0
142304831 skhammad B Jan. 10, 2022, 7:33 p.m. OK Java 11 TESTS 15 186 0
142324026 Satyaa B Jan. 11, 2022, 4:42 a.m. OK Java 11 TESTS 19 186 0
142318937 Robertino B Jan. 11, 2022, 3:05 a.m. OK Java 11 TESTS 19 186 0
142288591 SangramH123 B Jan. 10, 2022, 4:49 p.m. OK Java 8 TESTS 2 93 0
142326365 lcheeme1 B Jan. 11, 2022, 5:17 a.m. OK Java 8 TESTS 19 108 0
142327011 DEMO23 B Jan. 11, 2022, 5:24 a.m. OK Java 8 TESTS 19 108 0
142324855 kishan963 B Jan. 11, 2022, 4:55 a.m. OK Java 8 TESTS 19 108 4915200
142318165 zxz_xmx B Jan. 11, 2022, 2:47 a.m. OK Java 8 TESTS 19 109 0
142312282 bestgirl B Jan. 10, 2022, 10:52 p.m. OK Java 8 TESTS 19 109 0
142315683 WalrusRamen21 B Jan. 11, 2022, 1:36 a.m. OK Java 8 TESTS 19 124 0
142289545 amit_roy B Jan. 10, 2022, 4:53 p.m. OK Java 8 TESTS 2 140 0
142291598 gauravbajaj B Jan. 10, 2022, 5:05 p.m. OK Java 8 TESTS 2 155 0
142294613 beingshuchi B Jan. 10, 2022, 5:28 p.m. OK Java 8 TESTS 5 155 0
142288121 Quasar14 B Jan. 10, 2022, 4:49 p.m. OK Kotlin 1.4 TESTS 2 202 204800
142297145 Pasha831 B Jan. 10, 2022, 5:54 p.m. OK Kotlin 1.5 TESTS 12 311 0
142312285 bluemegane B Jan. 10, 2022, 10:53 p.m. OK Mono C# TESTS 19 93 2969600
142286882 BrynnW B Jan. 10, 2022, 4:47 p.m. OK MS C++ 2017 TESTS 2 15 0
142319016 The_earth B Jan. 11, 2022, 3:07 a.m. OK MS C++ 2017 TESTS 19 31 0
142288189 astutulus B Jan. 10, 2022, 4:49 p.m. OK MS C++ 2017 TESTS 2 46 0
142294662 nartig B Jan. 10, 2022, 5:29 p.m. OK MS C++ 2017 TESTS 5 62 0
142305398 edfearay11 B Jan. 10, 2022, 7:43 p.m. OK MS C++ 2017 TESTS 15 62 0
142296612 temur_sherov B Jan. 10, 2022, 5:48 p.m. OK MS C++ 2017 TESTS 12 62 0
142323597 whswhswhs B Jan. 11, 2022, 4:35 a.m. OK MS C++ 2017 TESTS 19 62 0
142319743 WangChaoqwe B Jan. 11, 2022, 3:23 a.m. OK MS C++ 2017 TESTS 19 62 0
142321682 shaedi B Jan. 11, 2022, 4:01 a.m. OK MS C++ 2017 TESTS 19 77 0
142309592 giovannielias9500 B Jan. 10, 2022, 9:13 p.m. OK .NET Core C# TESTS 15 108 3072000
142286490 LecPix B Jan. 10, 2022, 4:46 p.m. OK .NET Core C# TESTS 2 124 3072000
142307422 Njkz B Jan. 10, 2022, 8:21 p.m. OK .NET Core C# TESTS 15 140 2764800
142291802 osato B Jan. 10, 2022, 5:07 p.m. OK Node.js TESTS 2 202 5222400
142310390 evgeny.poloznov B Jan. 10, 2022, 9:38 p.m. OK PHP TESTS 19 109 0
142289797 1_2_3_4_5_9 B Jan. 10, 2022, 4:55 p.m. OK PyPy 2 TESTS 2 93 3584000
142325979 wincss B Jan. 11, 2022, 5:12 a.m. OK PyPy 2 TESTS 19 140 1740800
142329271 PVR11 B Jan. 11, 2022, 5:50 a.m. OK PyPy 3 TESTS 19 140 6144000
142315032 whatshisbucket B Jan. 11, 2022, 1:13 a.m. OK PyPy 3 TESTS 19 140 6451200
142312456 ayshiff B Jan. 10, 2022, 11:02 p.m. OK PyPy 3 TESTS 19 155 5529600
142318327 ambs_ B Jan. 11, 2022, 2:51 a.m. OK PyPy 3 TESTS 19 155 7680000
142297061 zayn. B Jan. 10, 2022, 5:53 p.m. OK PyPy 3 TESTS 12 171 6758400
142320619 Ayushman_123 B Jan. 11, 2022, 3:40 a.m. OK PyPy 3 TESTS 19 171 6963200
142296147 deepanshu_pali B Jan. 10, 2022, 5:44 p.m. OK PyPy 3 TESTS 12 171 8806400
142322652 rahin1301 B Jan. 11, 2022, 4:19 a.m. OK PyPy 3 TESTS 19 186 7168000
142292976 ACoder_25 B Jan. 10, 2022, 5:15 p.m. OK PyPy 3 TESTS 5 187 9728000
142297336 zayn. B Jan. 10, 2022, 5:56 p.m. OK PyPy 3 TESTS 12 202 8089600
142326651 kyuremmantle B Jan. 11, 2022, 5:20 a.m. OK PyPy 3-64 TESTS 19 124 5222400
142289556 krishna369 B Jan. 10, 2022, 4:53 p.m. OK PyPy 3-64 TESTS 2 139 4710400
142321452 Code_Breaker101 B Jan. 11, 2022, 3:57 a.m. OK PyPy 3-64 TESTS 19 140 10137600
142296015 nitish420 B Jan. 10, 2022, 5:43 p.m. OK PyPy 3-64 TESTS 5 155 3788800
142305352 MistaAsh B Jan. 10, 2022, 7:42 p.m. OK PyPy 3-64 TESTS 15 171 5734400
142295922 mrobiul B Jan. 10, 2022, 5:42 p.m. OK PyPy 3-64 TESTS 5 248 512000
142294413 Arturo_02 B Jan. 10, 2022, 5:27 p.m. OK PyPy 3-64 TESTS 5 264 3891200
142295782 Kornelius B Jan. 10, 2022, 5:40 p.m. OK PyPy 3-64 TESTS 5 280 2969600
142305048 THEarchitect B Jan. 10, 2022, 7:36 p.m. OK PyPy 3-64 TESTS 15 280 8499200
142303307 sawvik.dipto10 B Jan. 10, 2022, 7:11 p.m. OK PyPy 3-64 TESTS 15 280 9932800
142292543 OLOGY B Jan. 10, 2022, 5:12 p.m. OK Python 2 TESTS 5 46 819200
142306954 tieros B Jan. 10, 2022, 8:11 p.m. OK Python 3 TESTS 15 77 0
142299830 XiWangEric B Jan. 10, 2022, 6:24 p.m. OK Python 3 TESTS 15 77 0
142295552 agw02010 B Jan. 10, 2022, 5:38 p.m. OK Python 3 TESTS 5 77 0
142293698 acmyhy B Jan. 10, 2022, 5:21 p.m. OK Python 3 TESTS 5 77 512000
142328359 Sai1766 B Jan. 11, 2022, 5:40 a.m. OK Python 3 TESTS 19 78 0
142315565 wolfofwallstreet1 B Jan. 11, 2022, 1:32 a.m. OK Python 3 TESTS 19 93 0
142312299 a_sann B Jan. 10, 2022, 10:53 p.m. OK Python 3 TESTS 19 93 0
142302683 dankealot B Jan. 10, 2022, 7:01 p.m. OK Python 3 TESTS 15 93 307200
142298318 Jyothi_Prakash B Jan. 10, 2022, 6:07 p.m. OK Python 3 TESTS 15 93 614400
142292655 kiritofeng B Jan. 10, 2022, 5:13 p.m. OK Python 3 TESTS 5 108 0
142290180 crazywulf B Jan. 10, 2022, 4:57 p.m. OK Ruby 3 TESTS 2 249 1843200

remove filters

Back to search problems