European Championship 2024 - Online Mirror (Unrated, 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
1949 European Championship 2024 - Online Mirror (Unrated, ICPC Rules, Teams Preferred) FINISHED False 18000 25905563 March 24, 2024, 10 a.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 3609 ) B Charming Meals PROGRAMMING binary search brute force greedy sortings

B'The Czech cuisine features n appetizers and n main dishes. The i -th appetizer has spiciness a_i , and the i -th main dish has spiciness b_i . A typical Czech meal consists of exactly one appetizer and one main dish. You want to pair up the n appetizers and n main dishes into n meals with each appetizer and each main dish being included in exactly one meal. Your meals shall surprise the diners, so you want the spiciness levels of the two parts of the same meal to be as different as possible. The charm of a meal is the difference (in absolute value) between the spiciness of the appetizer and the spiciness of the main dish. So, a meal consisting of an appetizer with spiciness x and a main dish with spiciness y has charm equal to |x-y| . You want to maximize the minimum charm of the resulting n meals. What is the largest possible value of the minimum charm that you can achieve? Each test contains multiple test cases. The first line contains an integer t ( 1 <= t <= 1 ,000 ) -- the number of test cases. The descriptions of the t test cases follow. The first line of each test case contains a single integer n ( 1 <= q n <= q 5 ,000 ) --the number of appetizers and main dishes. The second line of each test case contains n integers a_1, a_2, ldots, a_n ( 0 <= q a_i <= q 10^{9} ) -- the spicinesses of the n appetizers. The third line of each test case contains n integers b_1, b_2, ldots, b_n ( 0 <= q b_i <= q 10^{9} ) -- the spicinesses of the n main dishes. It is guaranteed that the sum of n^2 over all test cases does not exceed 25 cdot 10^6 . For each test case, print the largest possible value of the minimum charm you can achieve. In the first test case, no matter how you pair up the appetizers with the main dishes, each meal will have an appetizer with spiciness 0 and a main dish with spiciness'...

Tutorials

European Championship 2024 (EUC) Editorial

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
253067330 LYXin B March 24, 2024, 10:39 a.m. OK C++14 (GCC 6-32) TESTS 30 93 0
253067259 ImmortaLimit StarSilk Su_Zipei B March 24, 2024, 10:38 a.m. OK C++14 (GCC 6-32) TESTS 30 93 0
253109505 TrendBattles B March 24, 2024, 4:03 p.m. OK C++14 (GCC 6-32) TESTS 30 108 204800
253152458 luogu_bot3 B March 25, 2024, 2:35 a.m. OK C++14 (GCC 6-32) TESTS 30 109 0
253091883 lcx2007 liujg xiaozengX B March 24, 2024, 1:43 p.m. OK C++14 (GCC 6-32) TESTS 30 124 0
253072987 tamp_ mahmoudbadawy Yousef_Salama B March 24, 2024, 11:20 a.m. OK C++14 (GCC 6-32) TESTS 30 124 102400
253073582 Razvan_Rotaru B March 24, 2024, 11:25 a.m. OK C++14 (GCC 6-32) TESTS 30 124 3174400
253068617 F7487 wgszcz kakaisjr B March 24, 2024, 10:48 a.m. OK C++14 (GCC 6-32) TESTS 30 140 0
253067796 A.n.o.n.y.m.o.u.s B March 24, 2024, 10:42 a.m. OK C++14 (GCC 6-32) TESTS 30 140 102400
253063846 flying jucason_xu pp_orange B March 24, 2024, 10:14 a.m. OK C++14 (GCC 6-32) TESTS 30 156 0
253138761 WLZ B March 24, 2024, 9:16 p.m. OK C++17 (GCC 7-32) TESTS 30 78 204800
253074573 Aminour_35 Kz_MaruF__ adilsadman60 B March 24, 2024, 11:32 a.m. OK C++17 (GCC 7-32) TESTS 30 93 0
253104194 Eftekhar_Nahim B March 24, 2024, 3:15 p.m. OK C++17 (GCC 7-32) TESTS 30 93 204800
253067422 RajiunNabi AfnanRakib Rafy55 B March 24, 2024, 10:40 a.m. OK C++17 (GCC 7-32) TESTS 30 93 204800
253148154 N_z__ B March 25, 2024, 12:40 a.m. OK C++17 (GCC 7-32) TESTS 30 93 307200
253062830 ship2077 User_Carrot N_z__ B March 24, 2024, 10:06 a.m. OK C++17 (GCC 7-32) TESTS 30 93 307200
253063995 Cirno_9baka A.K.E.E. QAQAutoMaton B March 24, 2024, 10:15 a.m. OK C++17 (GCC 7-32) TESTS 30 93 409600
253112299 ademby B March 24, 2024, 4:30 p.m. OK C++17 (GCC 7-32) TESTS 30 108 0
253067965 Moyogi GH1hatem Iceberg B March 24, 2024, 10:44 a.m. OK C++17 (GCC 7-32) TESTS 30 108 0
253067407 TravellingSalesman B March 24, 2024, 10:40 a.m. OK C++17 (GCC 7-32) TESTS 30 108 0
253147864 cmk666 B March 25, 2024, 12:33 a.m. OK C++20 (GCC 13-64) TESTS 30 31 512000
253149846 ship2077 B March 25, 2024, 1:23 a.m. OK C++20 (GCC 13-64) TESTS 30 46 102400
253114802 leovl48 B March 24, 2024, 4:55 p.m. OK C++20 (GCC 13-64) TESTS 30 46 102400
253064352 mcdx9524 erankyun Andreasyan B March 24, 2024, 10:17 a.m. OK C++20 (GCC 13-64) TESTS 30 46 102400
253150722 ship2077 B March 25, 2024, 1:48 a.m. OK C++20 (GCC 13-64) TESTS 30 61 102400
253065199 misteg168 BernatP Esomer B March 24, 2024, 10:24 a.m. OK C++20 (GCC 13-64) TESTS 30 61 102400
253156315 TJ_Andeviking B March 25, 2024, 3:52 a.m. OK C++20 (GCC 13-64) TESTS 30 62 102400
253143776 cotato B March 24, 2024, 10:48 p.m. OK C++20 (GCC 13-64) TESTS 30 62 102400
253104859 Kira_1234 B March 24, 2024, 3:21 p.m. OK C++20 (GCC 13-64) TESTS 30 62 102400
253086960 Irmuun.Ch B March 24, 2024, 1:06 p.m. OK C++20 (GCC 13-64) TESTS 30 62 102400
253066555 passwordisa spuh susvant B March 24, 2024, 10:34 a.m. OK Java 21 TESTS 30 374 0
253149808 Yousef_Badr B March 25, 2024, 1:23 a.m. OK Java 21 TESTS 30 405 102400
253149750 Yousef_Badr B March 25, 2024, 1:21 a.m. OK Java 21 TESTS 30 421 307200
253065077 mkah123 B March 24, 2024, 10:23 a.m. OK Java 21 TESTS 30 436 102400
253073142 kevin_Durant_ mao_wei_jia jinfeng123321 B March 24, 2024, 11:21 a.m. OK Java 21 TESTS 30 733 307200
253078874 yvbf B March 24, 2024, 12:05 p.m. OK Java 8 TESTS 30 202 0
253109390 venky57 B March 24, 2024, 4:02 p.m. OK Java 8 TESTS 30 561 0
253109213 venky57 B March 24, 2024, 4:01 p.m. OK Java 8 TESTS 30 655 0
253075500 alexey.enkov B March 24, 2024, 11:39 a.m. OK Kotlin 1.7 TESTS 30 1434 60518400
253062609 arvindf232 B March 24, 2024, 10:04 a.m. OK Kotlin 1.9 TESTS 30 233 819200
253064435 SlavaG B March 24, 2024, 10:18 a.m. OK Kotlin 1.9 TESTS 30 467 1126400
253065970 itsniklas pwolle xxxodarap B March 24, 2024, 10:30 a.m. OK PyPy 3 TESTS 30 795 9830400
253081797 the_last_smilodon B March 24, 2024, 12:27 p.m. OK PyPy 3-64 TESTS 30 327 8908800
253107154 rath772k B March 24, 2024, 3:42 p.m. OK PyPy 3-64 TESTS 30 358 10035200
253137662 sanya B March 24, 2024, 9:01 p.m. OK PyPy 3-64 TESTS 30 373 9318400
253112772 conqueror_of_tourist amsraman int_jim B March 24, 2024, 4:34 p.m. OK PyPy 3-64 TESTS 30 373 9830400
253122648 dhru72 B March 24, 2024, 6:14 p.m. OK PyPy 3-64 TESTS 30 420 9932800
253072358 mat_deg loumock B March 24, 2024, 11:16 a.m. OK PyPy 3-64 TESTS 30 420 9932800
253075893 amar3ndar B March 24, 2024, 11:42 a.m. OK PyPy 3-64 TESTS 30 421 9625600
253063133 AyuAnchor B March 24, 2024, 10:08 a.m. OK PyPy 3-64 TESTS 30 421 11264000
253076447 Synaptic_Savant B March 24, 2024, 11:45 a.m. OK PyPy 3-64 TESTS 30 623 7475200
253063208 Volk_zevaet B March 24, 2024, 10:09 a.m. OK PyPy 3-64 TESTS 30 670 9420800

remove filters

Back to search problems