Codeforces Round 573 (Div. 2)

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
1191 Codeforces Round 573 (Div. 2) FINISHED False 7200 168881099 July 12, 2019, 2:35 p.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 9618 ) B Tokitsukaze and Mahjong PROGRAMMING brute force implementation 1200

B"Tokitsukaze is playing a game derivated from Japanese mahjong. In this game, she has three tiles in her hand. Each tile she owns is a suited tile, which means it has a suit (manzu, pinzu or souzu) and a number (a digit ranged from 1 to 9 ). In this problem, we use one digit and one lowercase letter, which is the first character of the suit, to represent a suited tile. All possible suited tiles are represented as 1m, 2m, ldots , 9m, 1p, 2p, ldots , 9p, 1s, 2s, ldots , 9s. In order to win the game, she must have at least one mentsu (described below) in her hand, so sometimes she should draw extra suited tiles. After drawing a tile, the number of her tiles increases by one. She can draw any tiles she wants, including those already in her hand. Do you know the minimum number of extra suited tiles she needs to draw so that she can win? Here are some useful definitions in this game: Some examples: Note that the order of tiles is unnecessary and you can assume the number of each type of suited tiles she can draw is infinite. The only line contains three strings -- the tiles in Tokitsukaze's hand. For each string, the first character is a digit ranged from 1 to 9 and the second character is m, p or s. Print a single integer -- the minimum number of extra suited tiles she needs to draw. In the first example, Tokitsukaze already has a shuntsu. In the second example, Tokitsukaze already has a koutsu. In the third example, Tokitsukaze can get a shuntsu by drawing one suited tile -- 1p or 4p. The resulting tiles will be [3p, 9m, 2p, 1p] or [3p, 9m, 2p, 4p]. "...

Tutorials

68314

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
56969699 b_satyadev B July 13, 2019, 9:42 a.m. OK Clang++17 Diagnostics TESTS 213 46 0 1200
56960138 LaSWeeG B July 13, 2019, 6:16 a.m. OK Delphi TESTS 213 31 0 1200
57297832 romanporsh B July 18, 2019, 8:28 p.m. OK FPC TESTS 213 31 102400 1200
56952229 ldn060904 B July 13, 2019, 2:42 a.m. OK FPC TESTS 213 31 102400 1200
56961977 ti19_btvan B July 13, 2019, 6:58 a.m. OK FPC TESTS 213 31 102400 1200
57802234 luogu_bot3 B July 26, 2019, 1:43 p.m. OK FPC TESTS 213 46 102400 1200
56927694 bao-gpmn B July 12, 2019, 4:09 p.m. OK FPC TESTS 213 46 102400 1200
56924771 HQT2003 B July 12, 2019, 4 p.m. OK FPC TESTS 213 46 102400 1200
56975846 HoangVu123 B July 13, 2019, 12:12 p.m. OK FPC TESTS 213 46 102400 1200
62951436 MHHasan B Oct. 19, 2019, 6:57 p.m. OK GNU C11 TESTS 213 31 0 1200
61020985 nikhilreddy123 B Sept. 21, 2019, 2:35 p.m. OK GNU C11 TESTS 213 31 0 1200
59273770 srijamk B Aug. 22, 2019, 1:43 p.m. OK GNU C11 TESTS 213 31 0 1200
58914591 IndianPirate B Aug. 16, 2019, 2:25 p.m. OK GNU C11 TESTS 213 31 0 1200
57161855 tiwari.rahul1998 B July 16, 2019, 7:32 p.m. OK GNU C11 TESTS 213 31 0 1200
57332711 the_anomaly B July 19, 2019, 2:49 p.m. OK GNU C11 TESTS 213 31 0 1200
57381368 cs234_shrey B July 20, 2019, 2:42 p.m. OK GNU C11 TESTS 213 31 0 1200
57801630 rubber_duckieOwOwO B July 26, 2019, 1:30 p.m. OK GNU C11 TESTS 213 31 0 1200
57937681 MRoy B July 29, 2019, 11:25 a.m. OK GNU C11 TESTS 213 31 0 1200
57955378 ktk54x B July 29, 2019, 6:26 p.m. OK GNU C11 TESTS 213 31 0 1200
68694149 vjudge5 B Jan. 13, 2020, 7:19 a.m. OK GNU C++11 TESTS 213 31 0 1200
69817110 vjudge5 B Jan. 30, 2020, 6:32 a.m. OK GNU C++11 TESTS 213 31 0 1200
69577959 _Kema_ B Jan. 26, 2020, 4:13 p.m. OK GNU C++11 TESTS 213 31 0 1200
69613721 zhaoxiaoyun B Jan. 27, 2020, 12:28 p.m. OK GNU C++11 TESTS 213 31 0 1200
69808568 vjudge1 B Jan. 30, 2020, 3:16 a.m. OK GNU C++11 TESTS 213 31 0 1200
69462210 sanchit_div2 B Jan. 24, 2020, 11:17 a.m. OK GNU C++11 TESTS 213 31 0 1200
69191076 sunchuangyu B Jan. 20, 2020, 1:31 p.m. OK GNU C++11 TESTS 213 31 0 1200
69189999 sunchuangyu B Jan. 20, 2020, 1:13 p.m. OK GNU C++11 TESTS 213 31 0 1200
69055548 Wilderzzz B Jan. 18, 2020, 2:20 p.m. OK GNU C++11 TESTS 213 31 0 1200
69027283 dongyajie B Jan. 18, 2020, 7:27 a.m. OK GNU C++11 TESTS 213 31 0 1200
56949831 OO0OO0OO0OO0 B July 13, 2019, 1:35 a.m. OK GNU C++14 TESTS 213 30 0 1200
69805921 jaberndc B Jan. 30, 2020, 1:49 a.m. OK GNU C++14 TESTS 213 31 0 1200
69673775 SUGA_AUGUST-D B Jan. 28, 2020, 1:44 p.m. OK GNU C++14 TESTS 213 31 0 1200
69673683 SUGA_AUGUST-D B Jan. 28, 2020, 1:42 p.m. OK GNU C++14 TESTS 213 31 0 1200
69662474 warrior99 B Jan. 28, 2020, 9:59 a.m. OK GNU C++14 TESTS 213 31 0 1200
69655928 All1gator B Jan. 28, 2020, 7:27 a.m. OK GNU C++14 TESTS 213 31 0 1200
69626243 arv77 B Jan. 27, 2020, 3:53 p.m. OK GNU C++14 TESTS 213 31 0 1200
69624441 alirezarznia B Jan. 27, 2020, 3:23 p.m. OK GNU C++14 TESTS 213 31 0 1200
69548266 Xetrazeus B Jan. 26, 2020, 4:52 a.m. OK GNU C++14 TESTS 213 31 0 1200
69288060 kwok B Jan. 22, 2020, 9:03 a.m. OK GNU C++14 TESTS 213 31 0 1200
57006945 YGBoss007 B July 14, 2019, 7:17 a.m. OK GNU C++17 TESTS 213 30 0 1200
58644379 karansiwach360 B Aug. 12, 2019, 5:11 a.m. OK GNU C++17 TESTS 213 30 0 1200
57315762 vjudge1 B July 19, 2019, 8:09 a.m. OK GNU C++17 TESTS 213 30 0 1200
56974876 nwpu_yyf B July 13, 2019, 11:50 a.m. OK GNU C++17 TESTS 213 30 0 1200
69584923 xt0r3 B Jan. 26, 2020, 7 p.m. OK GNU C++17 TESTS 213 31 0 1200
69616640 ChandVachhani_ B Jan. 27, 2020, 1:16 p.m. OK GNU C++17 TESTS 213 31 0 1200
69623492 AbduSharif B Jan. 27, 2020, 3:08 p.m. OK GNU C++17 TESTS 213 31 0 1200
69672309 kratos000 B Jan. 28, 2020, 1:20 p.m. OK GNU C++17 TESTS 213 31 0 1200
69849288 omar_hany B Jan. 30, 2020, 3:09 p.m. OK GNU C++17 TESTS 213 31 0 1200
69902190 manovik18 B Jan. 31, 2020, 1:17 p.m. OK GNU C++17 TESTS 213 31 0 1200
60413858 sighduck B Sept. 12, 2019, 12:28 a.m. OK Go TESTS 213 46 0 1200
57475617 sbh B July 21, 2019, 9:17 p.m. OK Go TESTS 213 46 0 1200
57193496 hoangtl B July 17, 2019, 11:26 a.m. OK Go TESTS 213 46 0 1200
68673321 TheDarkKnight03 B Jan. 12, 2020, 5:35 p.m. OK Java 11 TESTS 213 186 0 1200
69637528 adamjamil B Jan. 27, 2020, 7:17 p.m. OK Java 11 TESTS 213 202 0 1200
66569723 Oopsimbad B Dec. 10, 2019, 3:13 a.m. OK Java 8 TESTS 213 109 0 1200
58849803 garnacha B Aug. 15, 2019, 7:02 a.m. OK Java 8 TESTS 213 109 0 1200
58412813 LeamyCodes B Aug. 7, 2019, 2:45 a.m. OK Java 8 TESTS 213 109 0 1200
58145724 ISSAM_LAKOUAM B Aug. 1, 2019, 9:03 p.m. OK Java 8 TESTS 213 109 0 1200
57007946 anto777 B July 14, 2019, 7:46 a.m. OK Java 8 TESTS 213 109 0 1200
57002134 ujjwalsingh30 B July 14, 2019, 4:28 a.m. OK Java 8 TESTS 213 109 0 1200
56994544 maheshwari29 B July 13, 2019, 8:46 p.m. OK Java 8 TESTS 213 109 0 1200
56989282 Harbin B July 13, 2019, 5:20 p.m. OK Java 8 TESTS 213 109 0 1200
68702063 akshVerma B Jan. 13, 2020, 9:48 a.m. OK Java 8 TESTS 213 124 0 1200
67444833 MagentaCobra B Dec. 22, 2019, 9:24 p.m. OK Java 8 TESTS 213 124 0 1200
56924819 mongolrgata B July 12, 2019, 4 p.m. OK JavaScript TESTS 213 46 102400 1200
57347331 a7md-sh3lan B July 20, 2019, 12:43 a.m. OK JavaScript TESTS 213 46 204800 1200
57245420 HossamHoussien B July 17, 2019, 7:09 p.m. OK JavaScript TESTS 213 46 307200 1200
57334817 Flame239 B July 19, 2019, 3:39 p.m. OK Kotlin TESTS 213 155 0 1200
57182170 Spheniscine B July 17, 2019, 7:36 a.m. OK Kotlin TESTS 213 156 1126400 1200
68948233 david_varela B Jan. 16, 2020, 4:58 p.m. OK Kotlin TESTS 213 156 1228800 1200
56951721 Zanmato B July 13, 2019, 2:31 a.m. OK Kotlin TESTS 213 171 1331200 1200
57075819 Yoshinaz B July 15, 2019, 5:07 a.m. OK Kotlin TESTS 213 186 1536000 1200
65238024 nastya1199 B Nov. 17, 2019, 7:57 a.m. OK Mono C# TESTS 213 61 0 1200
56943402 ansergeyg B July 12, 2019, 8:19 p.m. OK Mono C# TESTS 213 62 0 1200
59613353 treasuryonly B Aug. 28, 2019, 11:45 a.m. OK Mono C# TESTS 213 62 0 1200
57369242 zazak B July 20, 2019, 10:17 a.m. OK Mono C# TESTS 213 62 0 1200
57096779 octavian27 B July 15, 2019, 12:30 p.m. OK Mono C# TESTS 213 62 102400 1200
58110983 TheBaker B Aug. 1, 2019, 7:08 a.m. OK Mono C# TESTS 213 62 3686400 1200
58109840 TheChecker B Aug. 1, 2019, 6:35 a.m. OK Mono C# TESTS 213 62 3686400 1200
56974101 aliaksei.smaliuk B July 13, 2019, 11:31 a.m. OK Mono C# TESTS 213 62 3891200 1200
57740423 ololonso B July 25, 2019, 11:17 a.m. OK Mono C# TESTS 213 77 3584000 1200
57978010 NEvOl B July 30, 2019, 8:21 a.m. OK Mono C# TESTS 213 78 3686400 1200
66970008 vjudge1 B Dec. 15, 2019, 12:56 p.m. OK MS C++ TESTS 213 31 0 1200
69457499 vjudge1 B Jan. 24, 2020, 9:15 a.m. OK MS C++ TESTS 213 31 0 1200
66969580 vjudge4 B Dec. 15, 2019, 12:48 p.m. OK MS C++ TESTS 213 31 0 1200
66935488 vjudge5 B Dec. 15, 2019, 8:22 a.m. OK MS C++ TESTS 213 31 0 1200
66935052 vjudge4 B Dec. 15, 2019, 8:15 a.m. OK MS C++ TESTS 213 31 0 1200
66899230 vjudge2 B Dec. 15, 2019, 4:21 a.m. OK MS C++ TESTS 213 31 0 1200
66320809 vjudge2 B Dec. 5, 2019, 1:57 p.m. OK MS C++ TESTS 213 31 0 1200
64554623 vjudge4 B Nov. 9, 2019, 2:41 a.m. OK MS C++ TESTS 213 31 0 1200
64530123 vjudge2 B Nov. 8, 2019, 3:08 p.m. OK MS C++ TESTS 213 31 0 1200
64184065 vjudge1 B Nov. 4, 2019, 3:32 a.m. OK MS C++ TESTS 213 31 0 1200
57793241 lzstudy B July 26, 2019, 10:23 a.m. OK MS C++ 2017 TESTS 213 31 0 1200
57839210 vjudge3 B July 27, 2019, 8:41 a.m. OK MS C++ 2017 TESTS 213 31 0 1200
58544756 zhangfond B Aug. 10, 2019, 4:01 p.m. OK MS C++ 2017 TESTS 213 31 0 1200
61861489 vjudge3 B Oct. 4, 2019, 3:28 p.m. OK MS C++ 2017 TESTS 213 31 0 1200
61950006 shio B Oct. 6, 2019, 2:50 a.m. OK MS C++ 2017 TESTS 213 31 0 1200
64069789 vjudge4 B Nov. 2, 2019, 7:01 a.m. OK MS C++ 2017 TESTS 213 31 0 1200
64069916 vjudge4 B Nov. 2, 2019, 7:04 a.m. OK MS C++ 2017 TESTS 213 31 0 1200
66895889 vjudge2 B Dec. 15, 2019, 1:40 a.m. OK MS C++ 2017 TESTS 213 31 0 1200
67030188 RONGER B Dec. 16, 2019, 3:37 p.m. OK MS C++ 2017 TESTS 213 31 0 1200
68693973 lcjWA B Jan. 13, 2020, 7:16 a.m. OK MS C++ 2017 TESTS 213 31 0 1200
59594197 evanli2014 B Aug. 27, 2019, 11:40 p.m. OK Node.js TESTS 213 171 409600 1200
56928178 Bekzaat17 B July 12, 2019, 4:10 p.m. OK PHP TESTS 213 46 409600 1200
56940273 mayakin B July 12, 2019, 7:04 p.m. OK PHP TESTS 213 61 512000 1200
60779634 soyluy B Sept. 18, 2019, 3:47 p.m. OK PyPy 2 TESTS 213 124 0 1200
60359769 frostD B Sept. 10, 2019, 5:43 p.m. OK PyPy 2 TESTS 213 124 0 1200
57014403 Madhur1906 B July 14, 2019, 10:56 a.m. OK PyPy 2 TESTS 213 124 0 1200
60237520 petabyte0 B Sept. 7, 2019, 7:13 p.m. OK PyPy 2 TESTS 213 139 0 1200
57157254 jolt.tks B July 16, 2019, 5:15 p.m. OK PyPy 2 TESTS 213 139 0 1200
58987292 yumtam B Aug. 18, 2019, 7:41 a.m. OK PyPy 2 TESTS 213 140 0 1200
58495813 ssk497 B Aug. 9, 2019, 12:06 p.m. OK PyPy 2 TESTS 213 140 921600 1200
56979743 guduru.kranthikiran B July 13, 2019, 1:28 p.m. OK PyPy 2 TESTS 213 155 0 1200
57171187 GTrigger B July 17, 2019, 3:07 a.m. OK PyPy 2 TESTS 213 156 921600 1200
56941969 raj1307 B July 12, 2019, 7:37 p.m. OK PyPy 2 TESTS 213 187 0 1200
62572262 kfardeen7890 stunareeb_09 tarique.amucs B Oct. 14, 2019, 2:51 p.m. OK PyPy 3 TESTS 213 140 0 1200
60409680 ayshiff B Sept. 11, 2019, 8:36 p.m. OK PyPy 3 TESTS 213 140 0 1200
58545042 tungaqhd B Aug. 10, 2019, 4:09 p.m. OK PyPy 3 TESTS 213 140 0 1200
57157806 balani.mohit B July 16, 2019, 5:31 p.m. OK PyPy 3 TESTS 213 140 0 1200
57148482 Teddcp B July 16, 2019, 1:50 p.m. OK PyPy 3 TESTS 213 140 0 1200
57115165 ArtemGucci B July 15, 2019, 7:35 p.m. OK PyPy 3 TESTS 213 140 0 1200
56988563 dmitrii.krasnihin B July 13, 2019, 4:59 p.m. OK PyPy 3 TESTS 213 140 0 1200
56962848 Aidos B July 13, 2019, 7:16 a.m. OK PyPy 3 TESTS 213 140 0 1200
56962599 g2k B July 13, 2019, 7:10 a.m. OK PyPy 3 TESTS 213 140 0 1200
56955361 yellowflash B July 13, 2019, 4:27 a.m. OK PyPy 3 TESTS 213 140 0 1200
57102821 shubhankarsharma00 B July 15, 2019, 2:21 p.m. OK Python 2 TESTS 213 186 0 1200
56993761 elistark B July 13, 2019, 8:06 p.m. OK Python 2 TESTS 213 186 0 1200
56995628 google13 B July 13, 2019, 9:53 p.m. OK Python 2 TESTS 213 187 0 1200
56971404 SoSooding B July 13, 2019, 10:26 a.m. OK Python 2 TESTS 213 187 0 1200
56970515 pein_7 B July 13, 2019, 10:03 a.m. OK Python 2 TESTS 213 187 0 1200
56970417 pein_7 B July 13, 2019, 10 a.m. OK Python 2 TESTS 213 187 0 1200
60484878 uncle_c B Sept. 13, 2019, 12:13 p.m. OK Python 2 TESTS 213 202 0 1200
57007100 cool_heisenberg B July 14, 2019, 7:21 a.m. OK Python 2 TESTS 213 202 0 1200
60237149 chgliu B Sept. 7, 2019, 7:02 p.m. OK Python 3 TESTS 213 109 0 1200
69268105 Roms B Jan. 21, 2020, 7:27 p.m. OK Python 3 TESTS 213 109 307200 1200
57194451 msakshamsinghn B July 17, 2019, 11:44 a.m. OK Python 3 TESTS 213 109 307200 1200
56992108 drusha B July 13, 2019, 6:57 p.m. OK Python 3 TESTS 213 109 307200 1200
62940934 gswetha1713 B Oct. 19, 2019, 3:34 p.m. OK Python 3 TESTS 213 124 0 1200
59197041 nealzane B Aug. 21, 2019, 2:17 a.m. OK Python 3 TESTS 213 124 0 1200
58572575 darkshadow07 B Aug. 11, 2019, 10:54 a.m. OK Python 3 TESTS 213 124 0 1200
58496750 Dragneel_7 B Aug. 9, 2019, 12:29 p.m. OK Python 3 TESTS 213 124 0 1200
58103359 KanhuKeNanu B Aug. 1, 2019, 2:33 a.m. OK Python 3 TESTS 213 124 0 1200
58095210 disby B July 31, 2019, 7:23 p.m. OK Python 3 TESTS 213 124 0 1200
56951675 rinzu B July 13, 2019, 2:30 a.m. OK Ruby TESTS 213 92 204800 1200
56956092 Kaidora B July 13, 2019, 4:48 a.m. OK Ruby TESTS 213 108 204800 1200
57117334 NegrN7 B July 15, 2019, 9:11 p.m. OK Rust TESTS 213 46 0 1200
56941094 frozenlib B July 12, 2019, 7:19 p.m. OK Rust TESTS 213 46 0 1200

remove filters

Back to search problems