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 |
50
|
Codeforces Beta Round 47 |
FINISHED |
False |
7200 |
438961199 |
Dec. 20, 2010, 4:20 p.m. |
Problems
B"The Happy Farm 5 creators decided to invent the mechanism of cow grazing. The cows in the game are very slow and they move very slowly, it can even be considered that they stand still. However, carnivores should always be chased off them. For that a young player Vasya decided to make the shepherd run round the cows along one and the same closed path. It is very important that the cows stayed strictly inside the area limited by the path, as otherwise some cows will sooner or later be eaten. To be absolutely sure in the cows' safety, Vasya wants the path completion time to be minimum. The new game is launched for different devices, including mobile phones. That's why the developers decided to quit using the arithmetics with the floating decimal point and use only the arithmetics of integers. The cows and the shepherd in the game are represented as points on the plane with integer coordinates. The playing time is modeled by the turns. During every turn the shepherd can either stay where he stands or step in one of eight directions: horizontally, vertically, or diagonally. As the coordinates should always remain integer, then the length of a horizontal and vertical step is equal to 1, and the length of a diagonal step is equal to . The cows do not move. You have to minimize the number of moves the shepherd needs to run round the whole herd. The first line contains an integer N which represents the number of cows in the herd (1 xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89N xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89105). Each of the next N lines contains two integers Xi and Yi which represent the coordinates of one cow of (|Xi|, xe2 x80 x89|Yi| xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89106). Several cows can stand on one point. Print the single number -- the minimum number of moves in the sought path. Picture for the example test: The coordinate grid is painted grey, the coordinates axes are painted black, the cows are painted red and the sought route is painted green."... |
Tutorials
Submissions
Submission Id |
Author(s) |
Index |
Submitted |
Verdict |
Language |
Test Set |
Tests Passed |
Time taken (ms) |
Memory Consumed (bytes) |
Tags |
Rating |
40993284 |
ReaLNero1 |
C |
July 31, 2018, 1:52 a.m. |
OK |
GNU C++ |
TESTS |
75 |
92 |
0 |
|
2000 |
40410043 |
vjudge3 |
C |
July 16, 2018, noon |
OK |
GNU C++ |
TESTS |
75 |
218 |
3174400 |
|
2000 |
41288923 |
vjudge4 |
C |
Aug. 7, 2018, 12:21 a.m. |
OK |
GNU C++ |
TESTS |
75 |
218 |
3174400 |
|
2000 |
59412045 |
rainboy |
C |
Aug. 24, 2019, 4:16 p.m. |
OK |
GNU C11 |
TESTS |
75 |
92 |
0 |
|
2000 |
54151364 |
jiangly |
C |
May 15, 2019, 12:32 a.m. |
OK |
GNU C++11 |
TESTS |
75 |
62 |
4198400 |
|
2000 |
48912033 |
vjudge1 |
C |
Jan. 25, 2019, 2:55 a.m. |
OK |
GNU C++11 |
TESTS |
75 |
92 |
819200 |
|
2000 |
36291457 |
KCAH |
C |
March 15, 2018, 6:21 a.m. |
OK |
GNU C++11 |
TESTS |
75 |
92 |
1945600 |
|
2000 |
48912308 |
vjudge1 |
C |
Jan. 25, 2019, 3:09 a.m. |
OK |
GNU C++11 |
TESTS |
75 |
122 |
0 |
|
2000 |
51910243 |
TelmaZzzz |
C |
March 27, 2019, 5:46 p.m. |
OK |
GNU C++11 |
TESTS |
75 |
122 |
6963200 |
|
2000 |
48911712 |
vjudge1 |
C |
Jan. 25, 2019, 2:42 a.m. |
OK |
GNU C++11 |
TESTS |
75 |
124 |
16076800 |
|
2000 |
63061015 |
XyzL |
C |
Oct. 21, 2019, 8:40 a.m. |
OK |
GNU C++11 |
TESTS |
75 |
186 |
3174400 |
|
2000 |
53834848 |
luogu_bot3 |
C |
May 7, 2019, 1:25 a.m. |
OK |
GNU C++11 |
TESTS |
75 |
186 |
3276800 |
|
2000 |
30359581 |
McGinn |
C |
Sept. 15, 2017, 8:31 a.m. |
OK |
GNU C++11 |
TESTS |
75 |
186 |
6451200 |
|
2000 |
41222725 |
OgataRina |
C |
Aug. 4, 2018, 5 p.m. |
OK |
GNU C++11 |
TESTS |
75 |
216 |
3276800 |
|
2000 |
46021956 |
Naimur_Rahman_BSMRSTU |
C |
Nov. 21, 2018, 8:42 a.m. |
OK |
GNU C++14 |
TESTS |
75 |
92 |
0 |
|
2000 |
46021706 |
Naimur_Rahman_BSMRSTU |
C |
Nov. 21, 2018, 8:33 a.m. |
OK |
GNU C++14 |
TESTS |
75 |
92 |
0 |
|
2000 |
46021992 |
Naimur_Rahman_BSMRSTU |
C |
Nov. 21, 2018, 8:43 a.m. |
OK |
GNU C++14 |
TESTS |
75 |
92 |
0 |
|
2000 |
33897527 |
Cmise |
C |
Jan. 4, 2018, 7:06 a.m. |
OK |
GNU C++14 |
TESTS |
75 |
92 |
2662400 |
|
2000 |
46021896 |
Naimur_Rahman_BSMRSTU |
C |
Nov. 21, 2018, 8:40 a.m. |
OK |
GNU C++14 |
TESTS |
75 |
122 |
0 |
|
2000 |
46021673 |
Naimur_Rahman_BSMRSTU |
C |
Nov. 21, 2018, 8:32 a.m. |
OK |
GNU C++14 |
TESTS |
75 |
122 |
0 |
|
2000 |
46022187 |
Naimur_Rahman_BSMRSTU |
C |
Nov. 21, 2018, 8:50 a.m. |
OK |
GNU C++14 |
TESTS |
75 |
122 |
0 |
|
2000 |
55492640 |
aapc_image |
C |
June 12, 2019, 10:53 a.m. |
OK |
GNU C++14 |
TESTS |
75 |
124 |
0 |
|
2000 |
46021780 |
Naimur_Rahman_BSMRSTU |
C |
Nov. 21, 2018, 8:36 a.m. |
OK |
GNU C++14 |
TESTS |
75 |
124 |
0 |
|
2000 |
31604461 |
-Morass- |
C |
Oct. 22, 2017, 1:01 p.m. |
OK |
GNU C++14 |
TESTS |
75 |
124 |
1945600 |
|
2000 |
53807684 |
Curnurx |
C |
May 6, 2019, 3:08 a.m. |
OK |
GNU C++17 |
TESTS |
75 |
124 |
819200 |
|
2000 |
53807158 |
Curnurx |
C |
May 6, 2019, 2:29 a.m. |
OK |
GNU C++17 |
TESTS |
75 |
124 |
819200 |
|
2000 |
48912257 |
vjudge3 |
C |
Jan. 25, 2019, 3:07 a.m. |
OK |
GNU C++17 |
TESTS |
75 |
124 |
8294400 |
|
2000 |
48912706 |
vjudge4 |
C |
Jan. 25, 2019, 3:27 a.m. |
OK |
GNU C++17 |
TESTS |
75 |
124 |
16281600 |
|
2000 |
42283126 |
xuanquang1999 |
C |
Aug. 30, 2018, 3:25 p.m. |
OK |
GNU C++17 |
TESTS |
75 |
154 |
1024000 |
|
2000 |
51557425 |
tnakao |
C |
March 20, 2019, 5:51 a.m. |
OK |
GNU C++17 |
TESTS |
75 |
154 |
1638400 |
|
2000 |
48912807 |
vjudge5 |
C |
Jan. 25, 2019, 3:32 a.m. |
OK |
GNU C++17 |
TESTS |
75 |
186 |
307200 |
|
2000 |
46570344 |
sam7007 |
C |
Dec. 4, 2018, 5:08 a.m. |
OK |
GNU C++17 |
TESTS |
75 |
186 |
1638400 |
|
2000 |
66009981 |
Kuroni |
C |
Nov. 30, 2019, 1:47 a.m. |
OK |
GNU C++17 |
TESTS |
75 |
186 |
6348800 |
|
2000 |
55583909 |
chongryong |
C |
June 15, 2019, 8:22 a.m. |
OK |
GNU C++17 |
TESTS |
75 |
186 |
12800000 |
|
2000 |
59412044 |
Dukkha |
C |
Aug. 24, 2019, 4:16 p.m. |
OK |
Java 8 |
TESTS |
75 |
716 |
0 |
|
2000 |
53286570 |
vjudge5 |
C |
April 25, 2019, 2:06 p.m. |
OK |
MS C++ |
TESTS |
75 |
686 |
19251200 |
|
2000 |
35884338 |
______u______ |
C |
March 3, 2018, 1:09 p.m. |
OK |
Python 2 |
TESTS |
75 |
686 |
19968000 |
|
2000 |
35884244 |
______n______ |
C |
March 3, 2018, 1:09 p.m. |
OK |
Python 2 |
TESTS |
75 |
686 |
19968000 |
|
2000 |
35883297 |
_____k_____ |
C |
March 3, 2018, 12:51 p.m. |
OK |
Python 2 |
TESTS |
75 |
686 |
19968000 |
|
2000 |
35883121 |
_____i_____ |
C |
March 3, 2018, 12:50 p.m. |
OK |
Python 2 |
TESTS |
75 |
686 |
19968000 |
|
2000 |
35872725 |
______h______ |
C |
March 3, 2018, 7:16 a.m. |
OK |
Python 2 |
TESTS |
75 |
686 |
19968000 |
|
2000 |
35872589 |
______k______ |
C |
March 3, 2018, 7:14 a.m. |
OK |
Python 2 |
TESTS |
75 |
686 |
19968000 |
|
2000 |
35872064 |
______i______ |
C |
March 3, 2018, 7:04 a.m. |
OK |
Python 2 |
TESTS |
75 |
686 |
19968000 |
|
2000 |
35870161 |
______M______ |
C |
March 3, 2018, 6:22 a.m. |
OK |
Python 2 |
TESTS |
75 |
686 |
19968000 |
|
2000 |
56015888 |
sorry_im_smurfing |
C |
June 24, 2019, 9:08 p.m. |
OK |
Python 2 |
TESTS |
75 |
780 |
15462400 |
|
2000 |
38709744 |
Ali_Pi |
C |
May 29, 2018, 5:24 a.m. |
OK |
Python 2 |
TESTS |
75 |
780 |
15462400 |
|
2000 |
remove filters
Back to search problems