2020-2021 ICPC, NERC, Northern Eurasia Onsite (Unrated, Online Mirror, ICPC Rules, Teams Preferred)

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
1510 2020-2021 ICPC, NERC, Northern Eurasia Onsite (Unrated, Online Mirror, ICPC Rules, Teams Preferred) FINISHED False 18000 119656463 April 4, 2021, 8:05 a.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 1963 ) D Digits PROGRAMMING brute force dp math number theory

B"Diana loves playing with numbers. She's got n cards with positive integer numbers a_i written on them. She spends her free time multiplying the numbers on the cards. She picks a non-empty subset of the cards and multiplies all the numbers a_i written on them. Diana is happy when the product of the numbers ends with her favorite digit d . Now she is curious what cards she should pick so that the product of the numbers on them is the largest possible and the last decimal digit of the product is d . Please, help her. The first line contains the integers n and d ( 1 <= n <= 10^5 , 0 <= d <= 9 ). The second line contains n integers a_i ( 1 <= a_i <= 1000 ). On the first line, print the number of chosen cards k ( 1 <= k <= n ). On the next line, print the numbers written on the chosen cards in any order. If it is impossible to choose a subset of cards with the product that ends with the digit d , print the single line with -1 . In the first example, 1 x 2 x 4 x 11 x 13 = 1144 , which is the largest product that ends with the digit 4. The same set of cards without the number 1 is also a valid answer, as well as a set of 8, 11, and 13 with or without 1 that also has the product of 1144. In the second example, all the numbers on the cards are even and their product cannot end with an odd digit 1. In the third example, the only possible products are 1, 3, 5, 9, 15, and 45, none of which end with the digit 7. In the fourth example, 9 x 11 x 17 = 1683 , which ends with the digit 3. In the fifth example, 2 x 2 x 2 x 2 = 16 , which ends with the digit 6. "...

Tutorials

nerc-2020-offline-tutorial.pdf

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
112010570 Vilespine_Slayer D April 4, 2021, 2:34 p.m. OK GNU C++11 TESTS 52 31 1536000
111982518 Imakf waaitg Qiuly.qwq D April 4, 2021, 8:50 a.m. OK GNU C++11 TESTS 52 61 17510400
111987102 zhangguangxuan99 icypiggy jiefeng D April 4, 2021, 9:42 a.m. OK GNU C++11 TESTS 52 62 6553600
111999799 Inf_Voltage D April 4, 2021, 12:16 p.m. OK GNU C++11 TESTS 52 62 9523200
111985736 nwi D April 4, 2021, 9:26 a.m. OK GNU C++11 TESTS 52 62 13516800
111985347 AC-Evil Hongzy D April 4, 2021, 9:21 a.m. OK GNU C++11 TESTS 52 62 15564800
111982105 lwhlwh D April 4, 2021, 8:46 a.m. OK GNU C++11 TESTS 52 62 17510400
111982625 cbio zhaojinxi D April 4, 2021, 8:51 a.m. OK GNU C++11 TESTS 52 62 19046400
111983389 ustze Fuyuki EternalAlexander D April 4, 2021, 9 a.m. OK GNU C++11 TESTS 52 62 21504000
111983171 He_Ren RainAir D April 4, 2021, 8:58 a.m. OK GNU C++11 TESTS 52 62 31846400
111981765 Farhod_Farmon D April 4, 2021, 8:42 a.m. OK GNU C++14 TESTS 52 77 1945600
111988661 emperor_gentoo dakshgarg ankuragrawal D April 4, 2021, 10 a.m. OK GNU C++14 TESTS 52 78 12595200
112044469 NothingXD D April 5, 2021, 4:25 a.m. OK GNU C++14 TESTS 53 78 20684800
111990010 eddysboy numberes Alphagocc D April 4, 2021, 10:17 a.m. OK GNU C++14 TESTS 52 78 22323200
111989794 eddysboy numberes Alphagocc D April 4, 2021, 10:14 a.m. OK GNU C++14 TESTS 52 78 22323200
111987044 _Erased Stranger001 Prakhar314 D April 4, 2021, 9:42 a.m. OK GNU C++14 TESTS 52 93 14336000
112024414 obaydullahmhs D April 4, 2021, 5:53 p.m. OK GNU C++14 TESTS 52 93 16179200
111989635 gEisk D April 4, 2021, 10:12 a.m. OK GNU C++14 TESTS 52 93 17510400
111980536 BlueDiamond D April 4, 2021, 8:28 a.m. OK GNU C++14 TESTS 52 93 23449600
112048827 hellojim D April 5, 2021, 5:59 a.m. OK GNU C++14 TESTS 53 109 17510400
111989237 kupriyanov Phys-mat_KCh D April 4, 2021, 10:07 a.m. OK GNU C++17 TESTS 52 62 1945600
111994789 Sorting D April 4, 2021, 11:17 a.m. OK GNU C++17 TESTS 52 62 2355200
112045030 nanatoday D April 5, 2021, 4:41 a.m. OK GNU C++17 TESTS 53 62 3174400
111993580 hv44 _rishi_1001 sayam.sethi2 D April 4, 2021, 11:03 a.m. OK GNU C++17 TESTS 52 62 3174400
111984715 andr0901 D April 4, 2021, 9:14 a.m. OK GNU C++17 TESTS 52 62 3174400
111988711 lucaperju apostoldaniel854 ivan.tudor D April 4, 2021, 10:01 a.m. OK GNU C++17 TESTS 52 62 4608000
111983138 YxwKeith KristinAlter LighTcml D April 4, 2021, 8:56 a.m. OK GNU C++17 TESTS 52 62 14131200
112024555 7KIRA1999 D April 4, 2021, 5:55 p.m. OK GNU C++17 TESTS 52 62 14233600
111990259 mahdi.hasnat irri SA01 D April 4, 2021, 10:20 a.m. OK GNU C++17 TESTS 52 62 26316800
112008930 maverick16 D April 4, 2021, 2:12 p.m. OK GNU C++17 TESTS 52 77 1536000
112046465 hello_codeforces D April 5, 2021, 5:15 a.m. OK GNU C++17 (64) TESTS 53 46 1536000
111984093 BohdanPastuschak mshcherba PetroTarnavskyi D April 4, 2021, 9:07 a.m. OK GNU C++17 (64) TESTS 52 61 2252800
112048181 hello_codeforces D April 5, 2021, 5:47 a.m. OK GNU C++17 (64) TESTS 53 62 1536000
111984964 KKT_89 hotman78 Hyado D April 4, 2021, 9:17 a.m. OK GNU C++17 (64) TESTS 52 62 2252800
111986590 noimi math957963 jell D April 4, 2021, 9:36 a.m. OK GNU C++17 (64) TESTS 52 62 2662400
111996240 triple__a Nezzar Nanako D April 4, 2021, 11:34 a.m. OK GNU C++17 (64) TESTS 52 62 4505600
111985360 googol_S0 D April 4, 2021, 9:21 a.m. OK GNU C++17 (64) TESTS 52 62 7168000
111980172 webmaster D April 4, 2021, 8:24 a.m. OK GNU C++17 (64) TESTS 52 62 13516800
111990956 Lemonade255 D April 4, 2021, 10:29 a.m. OK GNU C++17 (64) TESTS 52 62 18739200
111989004 HCPS42 ALILILILILI-KHAN D April 4, 2021, 10:04 a.m. OK GNU C++17 (64) TESTS 52 77 6963200
111985316 0x3F D April 4, 2021, 9:21 a.m. OK Go TESTS 52 109 35123200
112020130 YahiaSherif D April 4, 2021, 4:45 p.m. OK Java 8 TESTS 52 296 14745600
112035997 Ahmed_Hosssam D April 4, 2021, 10:44 p.m. OK Java 8 TESTS 53 607 94924800
112023889 ThatIsToSay D April 4, 2021, 5:44 p.m. OK MS C++ 2017 TESTS 52 187 26419200
111997815 jimm89 D April 4, 2021, 11:53 a.m. OK PyPy 3 TESTS 52 420 17612800
112010785 Satwik_Tiwari D April 4, 2021, 2:37 p.m. OK PyPy 3 TESTS 52 592 32563200
111987961 Bruteforceman D April 4, 2021, 9:52 a.m. OK PyPy 3 TESTS 52 686 95539200
112037242 zucyo05 D April 4, 2021, 11:46 p.m. OK PyPy 3 TESTS 53 795 93286400
112008147 voidf D April 4, 2021, 2:01 p.m. OK PyPy 3 TESTS 52 1123 58368000
111981800 sansen D April 4, 2021, 8:42 a.m. OK Rust TESTS 52 124 13516800

remove filters

Back to search problems