QOJ.ac
QOJ
ID | Problem | Submitter | Result | Time | Memory | Language | File size | Submit time | Judge time |
---|---|---|---|---|---|---|---|---|---|
#54037 | #1292. Circuit Board Design | Baltinic | AC ✓ | 5ms | 4424kb | C++ | 1.4kb | 2022-10-06 17:40:55 | 2022-10-06 17:40:58 |
Judging History
answer
#include <bits/stdc++.h>
using namespace std;
#define rep(i, n) for (int i = 0; i < int(n); i++)
#define Rep(i, n) for (int i = 1; i <=int(n); i++)
#define range(x) begin(x), end(x)
#ifdef __LOCAL_DEBUG__
#define _debug(fmt, ...) fprintf(stderr, "[%s] " fmt "\n", __func__, ##__VA_ARGS__)
#else
#define _debug(...) ((void) 0)
#endif
typedef long long LL;
typedef unsigned long long ULL;
int n;
vector<int> adj[1024];
int sz[1024];
void dfs(int u, int p) {
if (adj[u].size() == 1 and p) {
sz[u] = 1;
return;
} else {
for (int v : adj[u]) {
if (v == p) continue;
dfs(v, u);
sz[u] += sz[v];
}
}
}
typedef complex<double> cplx;
cplx pos[1024];
void draw(int u, int p, cplx pt, double al, double ar) {
pos[u] = pt;
double slice = (ar - al) / sz[u], pos = al, npos;
for (int v : adj[u]) {
if (v == p) continue;
npos = pos + sz[v] * slice;
draw(v, u, pt + polar(1.0, (pos + npos) / 2.0), pos, npos);
pos = npos;
}
}
int main() {
scanf("%d", &n);
for (int i = 1; i < n; i++) {
int u, v; scanf("%d%d", &u, &v);
adj[u].push_back(v);
adj[v].push_back(u);
}
dfs(1, 0);
draw(1, 0, 0, 0, acos(-1));
Rep (i, n) printf("%.14f %.14f\n", pos[i].real(), pos[i].imag());
return 0;
}
Details
Tip: Click on the bar to expand more detailed information
Test #1:
score: 100
Accepted
time: 0ms
memory: 4424kb
input:
1000 1 2 2 3 3 4 4 5 5 6 6 7 7 8 8 9 9 10 10 11 11 12 12 13 13 14 14 15 15 16 16 17 17 18 18 19 19 20 20 21 21 22 22 23 23 24 24 25 25 26 26 27 27 28 28 29 29 30 30 31 31 32 32 33 33 34 34 35 35 36 36 37 37 38 38 39 39 40 40 41 41 42 42 43 43 44 44 45 45 46 46 47 47 48 48 49 49 50 50 51 51 52 52 53 ...
output:
0.00000000000000 0.00000000000000 0.00000000000000 1.00000000000000 0.00000000000000 2.00000000000000 0.00000000000000 3.00000000000000 0.00000000000000 4.00000000000000 0.00000000000000 5.00000000000000 0.00000000000000 6.00000000000000 0.00000000000000 7.00000000000000 0.00000000000000 8.000000000...
result:
ok
Test #2:
score: 0
Accepted
time: 5ms
memory: 4192kb
input:
1000 65 761 553 278 364 774 438 818 222 364 880 271 926 557 121 179 725 62 181 676 986 285 910 186 607 389 66 15 874 248 51 113 443 68 64 312 227 216 539 518 749 678 836 886 948 84 292 829 777 448 392 570 639 953 211 327 561 938 480 441 727 83 958 773 714 804 675 488 848 981 728 808 440 444 398 752 ...
output:
0.00000000000000 0.00000000000000 15.55634918610405 15.55634918610405 -504.87424176719838 504.87424176719838 -356.38181771802221 356.38181771802221 -412.95036021294646 412.95036021294646 -117.37972567696723 117.37972567696724 200.11121907579397 200.11121907579394 -299.81327522309795 299.813275223097...
result:
ok
Test #3:
score: 0
Accepted
time: 0ms
memory: 4204kb
input:
1000 1 2 1 3 2 4 2 5 3 6 3 7 4 8 4 9 5 10 5 11 6 12 6 13 7 14 7 15 8 16 8 17 9 18 9 19 10 20 10 21 11 22 11 23 12 24 12 25 13 26 13 27 14 28 14 29 15 30 15 31 16 32 16 33 17 34 17 35 18 36 18 37 19 38 19 39 20 40 20 41 21 42 21 43 22 44 22 45 23 46 23 47 24 48 24 49 25 50 25 51 26 52 26 53 27 54 27 ...
output:
0.00000000000000 0.00000000000000 0.69365330581280 0.72030902488791 -0.72030902488791 0.69365330581280 1.61388515317868 1.11168269172511 1.05006518452606 1.65463796734452 -1.14608831645298 1.59848035827882 -1.65463796734452 1.05006518452606 2.59374020556292 1.31139267223952 2.43741775080710 1.678951...
result:
ok
Test #4:
score: 0
Accepted
time: 4ms
memory: 4256kb
input:
1000 819 887 138 446 936 977 355 197 734 909 767 836 207 892 736 897 807 359 180 214 317 632 671 272 816 68 170 565 77 96 511 655 245 334 715 760 57 946 987 907 752 841 227 940 908 864 685 45 467 3 315 144 646 951 427 694 540 817 822 301 353 451 803 530 318 392 516 184 302 920 320 44 567 533 264 241...
output:
0.00000000000000 0.00000000000000 -2.58766036251779 7.32775619882909 7.12137361319663 11.08816168691847 2.18363754685033 15.48957942568260 6.10551562436258 5.35130033499841 -5.03961384243312 13.94937472733206 6.47098877938367 12.00917956455901 -3.09249626020479 11.63016106263335 5.64062193920034 11....
result:
ok
Test #5:
score: 0
Accepted
time: 3ms
memory: 4232kb
input:
1000 1 2 1 3 1 4 1 5 1 6 1 7 1 8 1 9 1 10 1 11 1 12 1 13 1 14 1 15 1 16 1 17 1 18 1 19 1 20 1 21 1 22 1 23 1 24 1 25 1 26 1 27 1 28 1 29 1 30 1 31 1 32 1 33 1 34 1 35 1 36 1 37 1 38 1 39 1 40 1 41 1 42 1 43 1 44 1 45 1 46 1 47 1 48 1 49 1 50 1 51 1 52 1 53 1 54 1 55 1 56 1 57 1 58 1 59 1 60 1 61 1 6...
output:
0.00000000000000 0.00000000000000 0.99999876382860 0.00157236804758 0.99998887447571 0.00471708859303 0.99996909586775 0.00786176248947 0.99993942820029 0.01100635863806 0.99989987176675 0.01415084594076 0.99985042695830 0.01729519330058 0.99979109426393 0.02043936962191 0.99972187427039 0.023583343...
result:
ok
Test #6:
score: 0
Accepted
time: 3ms
memory: 4200kb
input:
1000 183 171 183 657 183 966 183 197 183 604 183 391 183 59 183 330 183 424 183 436 183 113 183 708 183 366 183 557 183 431 183 446 183 105 183 836 183 196 183 795 183 64 183 117 183 994 183 892 183 396 183 776 183 267 183 594 183 315 183 726 183 224 183 274 183 158 183 972 183 952 183 469 183 347 1...
output:
0.00000000000000 0.00000000000000 -0.99063929702129 1.13650561599133 -0.96230555917937 1.27197060644944 0.48676623880103 1.87353227116318 0.89969676149844 1.43651544915297 0.97335319810396 1.22931103711073 0.75846039782378 1.65171913040281 -0.99771060987190 1.06762794503047 0.37321169396216 1.927746...
result:
ok
Test #7:
score: 0
Accepted
time: 1ms
memory: 4352kb
input:
1000 1 2 1 3 3 4 3 5 5 6 5 7 7 8 7 9 9 10 9 11 11 12 11 13 13 14 13 15 15 16 15 17 17 18 17 19 19 20 19 21 21 22 21 23 23 24 23 25 25 26 25 27 27 28 27 29 29 30 29 31 31 32 31 33 33 34 33 35 35 36 35 37 37 38 37 39 39 40 39 41 41 42 41 43 43 44 43 45 45 46 45 47 47 48 47 49 49 50 49 51 51 52 51 53 5...
output:
0.00000000000000 0.00000000000000 0.99999506520186 0.00314158748588 -0.00314158748588 0.99999506520186 0.99681399962307 1.00941970363500 -0.00942473145144 1.99997532605800 0.99045190103022 2.01568264336982 -0.01884936988458 2.99993091316695 0.98090883455240 3.02192028925945 -0.03141540976794 3.99985...
result:
ok
Test #8:
score: 0
Accepted
time: 5ms
memory: 4284kb
input:
1000 230 441 949 387 737 325 553 628 864 851 308 601 499 110 587 452 528 813 750 726 638 582 247 984 549 674 144 429 852 403 645 15 435 640 437 354 497 33 9 301 635 626 509 622 191 536 72 934 238 581 979 505 102 83 305 975 469 571 192 623 277 579 224 205 845 576 263 684 9 815 20 372 498 799 281 458 ...
output:
0.00000000000000 0.00000000000000 73.03808554714135 62.28951604043797 -4.28279893101011 3.78695677683571 155.06371523757599 127.81913836748616 154.33259964284613 127.13688475837677 34.18503206225354 30.55287404576158 -32.48868509671258 38.00550247431066 -103.67762431263492 117.79348751801186 -143.00...
result:
ok
Test #9:
score: 0
Accepted
time: 2ms
memory: 4300kb
input:
2 1 2
output:
0.00000000000000 0.00000000000000 0.00000000000000 1.00000000000000
result:
ok
Test #10:
score: 0
Accepted
time: 4ms
memory: 4064kb
input:
1000 1 2 1 3 1 4 3 5 3 6 3 7 5 8 5 9 5 10 9 11 9 12 9 13 13 14 13 15 13 16 15 17 15 18 15 19 18 20 18 21 18 22 20 23 20 24 20 25 23 26 23 27 23 28 27 29 27 30 27 31 31 32 31 33 31 34 33 35 33 36 33 37 37 38 37 39 37 40 39 41 39 42 39 43 43 44 43 45 43 46 45 47 45 48 45 49 47 50 47 51 47 52 50 53 50 ...
output:
0.00000000000000 0.00000000000000 0.99999722694879 0.00235501480484 0.00000000000000 1.00000000000000 -0.99999722694879 0.00235501480484 0.00471001654853 1.99998890781054 -0.99993067448872 1.01177481280266 -0.99997504263138 1.00706499216998 1.00468505917991 2.00705389998052 0.00942003309705 2.999977...
result:
ok
Test #11:
score: 0
Accepted
time: 3ms
memory: 4184kb
input:
135 46 63 35 41 56 36 46 119 108 64 113 98 66 27 73 7 24 109 49 108 23 1 69 22 8 32 39 82 7 130 114 16 36 80 129 50 51 39 7 3 121 59 124 133 93 23 69 44 124 85 48 122 27 14 108 135 104 25 104 5 44 87 66 106 94 78 18 4 28 104 56 118 133 61 44 18 62 68 108 70 45 26 10 125 30 54 17 74 44 95 123 126 59 ...
output:
0.00000000000000 0.00000000000000 -2.86598937301344 12.21456871275904 -2.82604872582174 3.76155906070477 -0.27825837696148 9.81843376791672 2.20825077296294 4.23472203270128 -1.46015167645974 12.69860975477315 -1.86342447887173 3.49071859256177 0.27357176161095 5.98292760258831 1.72825574321559 8.60...
result:
ok
Test #12:
score: 0
Accepted
time: 3ms
memory: 4020kb
input:
627 592 368 39 322 230 497 144 607 494 226 295 161 35 1 481 167 323 207 203 589 146 595 65 465 360 471 221 512 561 62 562 316 206 540 456 551 189 115 503 79 26 486 96 74 419 12 49 433 426 602 199 532 265 87 487 383 573 381 479 415 49 110 559 529 198 473 298 365 312 51 468 315 598 362 59 183 565 125 ...
output:
0.00000000000000 0.00000000000000 -2.81080726131526 8.03340395814211 2.75276518914161 11.08464290101370 5.63007652652565 12.48242975079557 -1.35733891167903 10.40200775262111 4.77628630045157 11.94318985678231 -3.73189646467044 8.42540267995093 4.47651307443900 10.53879323807671 -6.99766220217896 14...
result:
ok
Test #13:
score: 0
Accepted
time: 1ms
memory: 4200kb
input:
533 14 348 158 138 171 511 93 242 516 110 289 14 523 22 284 45 458 101 488 524 362 105 145 228 81 522 130 17 495 13 181 252 46 512 72 131 501 301 364 142 137 365 461 239 19 507 521 352 266 472 45 194 108 41 249 267 30 44 153 346 81 173 38 57 249 458 73 307 345 400 292 38 173 320 482 393 466 10 178 8...
output:
0.00000000000000 0.00000000000000 -0.56748481113523 12.85606726156747 5.46069454942227 9.43016623441051 -3.00899673459203 4.40110634429380 -1.02344863345924 6.21986629585613 -0.27441213444355 11.88570416827952 -4.05154100494339 9.95462967674218 0.77357112694314 10.90357611810129 2.06808657951884 11....
result:
ok
Test #14:
score: 0
Accepted
time: 0ms
memory: 4208kb
input:
638 223 432 636 391 75 130 151 550 274 134 549 351 103 475 93 399 89 258 556 558 262 153 535 216 292 16 424 187 555 281 181 520 382 436 93 122 62 274 274 561 512 532 352 597 550 424 489 181 55 366 348 397 486 28 435 204 209 161 436 631 92 135 350 409 183 100 354 21 140 268 338 568 382 41 626 156 422...
output:
0.00000000000000 0.00000000000000 -0.91141525319970 6.79559554283955 -0.45728969636687 8.94364438379613 2.49698934277454 8.32103966266828 -2.83055099541642 6.74858096756992 -4.46200148699744 7.93603986523139 0.46727323260967 9.94388839760434 -0.46849666104275 11.96155344709839 -1.07190454330823 5.64...
result:
ok
Test #15:
score: 0
Accepted
time: 2ms
memory: 4224kb
input:
300 253 83 57 111 74 109 67 151 10 55 285 52 76 259 225 288 159 88 10 120 36 286 145 54 124 219 299 148 281 296 170 244 239 160 24 31 81 154 224 149 66 162 64 291 239 96 275 191 85 40 138 25 5 257 60 165 275 47 62 185 229 87 275 242 84 236 25 135 24 79 165 110 25 189 15 13 156 24 50 163 293 16 191 9...
output:
0.00000000000000 0.00000000000000 -9.16877378010785 3.69355185899648 -3.88042863938736 4.49631480736359 -1.49056942507571 7.67630726342471 2.40862987167887 5.68824955054596 -1.97691079311469 9.62611596785751 0.92806509613629 8.87567755711021 0.14773618549875 4.95270227191253 3.75366079180962 3.32227...
result:
ok
Test #16:
score: 0
Accepted
time: 3ms
memory: 4116kb
input:
161 135 76 71 102 124 78 146 9 92 59 134 85 126 143 114 155 35 137 139 64 20 54 54 40 114 32 144 13 114 68 29 110 84 4 116 90 57 35 37 23 27 14 114 69 73 151 64 66 71 136 60 95 144 11 127 160 94 117 47 126 31 49 136 92 127 77 125 132 120 53 25 100 83 3 74 48 124 38 136 87 115 99 126 152 28 86 28 19 ...
output:
0.00000000000000 0.00000000000000 -3.42867826264743 9.08029778622187 0.92599344473357 5.47670112398313 0.02605341419034 5.90693340052237 1.36178708020025 6.41194764923649 1.02567925585063 6.60279844377758 1.63552239096662 7.41605244527695 2.98843324269395 3.25785459485093 -4.20883915674496 4.9415235...
result:
ok
Test #17:
score: 0
Accepted
time: 3ms
memory: 4212kb
input:
989 723 716 646 872 985 597 934 730 47 217 76 661 499 466 41 286 331 939 529 388 38 555 437 888 266 84 563 959 621 749 468 348 122 36 701 287 58 511 441 395 52 59 261 488 120 142 13 814 735 242 890 178 51 746 246 48 544 102 890 343 122 847 945 790 850 427 650 741 92 442 702 224 37 111 873 294 198 80...
output:
0.00000000000000 0.00000000000000 -0.27639784431243 10.84997731452354 -6.84540965968111 5.68263031456764 -1.24831283485024 5.37118745668699 -7.13363494329293 10.55404625785707 2.74313836121833 5.03654626862416 -6.15128082407930 10.21763665732294 -0.53612202636092 11.86535453624024 5.08843033635693 7...
result:
ok
Test #18:
score: 0
Accepted
time: 2ms
memory: 3984kb
input:
39 38 20 15 38 19 3 26 16 19 1 7 23 16 27 31 6 19 9 15 2 8 37 16 35 8 12 30 32 1 17 29 8 15 26 10 11 26 18 22 10 15 19 17 13 3 33 19 22 22 7 22 14 37 28 26 5 38 24 38 39 11 29 22 21 22 25 17 30 3 31 21 4 29 34 34 36
output:
0.00000000000000 0.00000000000000 1.13292352949573 2.73133502913760 1.14412280563537 1.14412280563537 -2.19829391199814 2.79309143562707 0.68840033409216 3.86330053911177 3.08886264643072 1.61101353334718 -1.14246163162014 2.50850027179520 -1.95008087476017 5.47078942002418 1.08031399755152 1.370371...
result:
ok
Test #19:
score: 0
Accepted
time: 3ms
memory: 4184kb
input:
429 150 408 322 291 266 66 329 218 402 55 189 102 93 141 402 283 217 281 318 24 25 309 107 16 267 45 303 227 260 232 123 84 273 391 377 284 429 191 273 32 386 39 184 2 383 397 142 297 392 371 348 17 208 46 275 181 394 65 12 164 297 276 289 51 365 386 422 175 108 298 397 200 99 422 222 243 275 367 11...
output:
0.00000000000000 0.00000000000000 2.16430805032285 7.44392467651322 -3.45835638389301 8.75150331148200 3.59525870795734 10.08495373431216 0.08141337716448 2.99668042120766 3.64712650598730 7.49973092785233 5.45095045908096 6.40064783407966 -3.40680223414368 8.79379495616639 -0.18731965251053 7.68475...
result:
ok
Test #20:
score: 0
Accepted
time: 1ms
memory: 4240kb
input:
1000 1 2 2 3 3 4 4 5 5 6 6 7 7 8 8 9 9 10 10 11 11 12 12 13 13 14 14 15 15 16 16 17 17 18 18 19 19 20 20 21 21 22 22 23 23 24 24 25 25 26 26 27 27 28 28 29 29 30 30 31 31 32 32 33 33 34 34 35 35 36 36 37 37 38 38 39 39 40 40 41 41 42 42 43 43 44 44 45 45 46 46 47 47 48 48 49 49 50 50 51 51 52 52 53 ...
output:
0.00000000000000 0.00000000000000 0.99999508488197 0.00313531687274 1.99999016976395 0.00627063374549 2.99998525464592 0.00940595061823 3.99998033952790 0.01254126749097 4.99997542440987 0.01567658436372 5.99997050929185 0.01881190123646 6.99996559417382 0.02194721810920 7.99996067905580 0.025082534...
result:
ok
Test #21:
score: 0
Accepted
time: 4ms
memory: 4280kb
input:
1000 955 799 959 651 864 679 622 459 622 511 42 753 622 227 622 94 622 444 299 234 622 295 622 219 622 205 622 897 771 406 689 415 646 86 357 351 622 212 622 300 622 951 622 904 622 262 622 772 678 83 241 564 882 798 622 285 479 968 859 271 622 296 413 26 622 755 622 190 622 884 3 736 622 759 326 57...
output:
0.00000000000000 0.00000000000000 -240.53292187685273 57.15081026471696 -42.84796988899387 11.00257348845157 -267.79981180621235 63.51608430282257 -359.33865656906107 84.88521857360568 -0.94194030070880 1.33578038939256 0.98817491911028 1.15333078373696 0.84264041216043 1.53847668082666 0.2578073882...
result:
ok
Test #22:
score: 0
Accepted
time: 3ms
memory: 4108kb
input:
1000 1 2 1 3 1 4 1 5 1 6 1 7 1 8 1 9 1 10 1 11 1 12 1 13 1 14 1 15 1 16 1 17 1 18 1 19 1 20 1 21 1 22 1 23 1 24 1 25 1 26 1 27 1 28 1 29 1 30 1 31 1 32 1 33 1 34 1 35 1 36 1 37 1 38 1 39 1 40 1 41 1 42 1 43 1 44 1 45 1 46 1 47 1 48 1 49 1 50 1 51 1 52 1 53 1 54 1 55 1 56 1 57 1 58 1 59 1 60 1 61 1 6...
output:
0.00000000000000 0.00000000000000 0.98743888867639 0.15800139597335 0.88883544865492 0.45822652172741 0.70147488770632 0.71269417137886 0.44406661260577 0.89599377429134 0.14231483827329 0.98982144188093 -0.17364817766693 0.98480775301221 -0.47227107477268 0.88145336344758 -0.72373403810507 0.690079...
result:
ok
Test #23:
score: 0
Accepted
time: 1ms
memory: 4160kb
input:
1000 687 479 95 429 175 205 95 687 762 563 682 776 762 419 175 47 142 387 175 494 376 963 687 412 376 817 142 458 201 238 175 143 762 572 142 381 95 801 687 618 762 323 682 685 762 655 201 287 687 513 762 334 682 702 175 438 682 745 121 886 58 731 762 41 201 360 58 10 142 120 682 35 201 176 201 566 ...
output:
0.00000000000000 0.00000000000000 2.04224126010951 2.37674359613499 -0.35840712652963 3.94698917349886 -0.45243825087778 3.91788313293565 0.45779138029418 3.95850186237433 0.49770735386345 3.94793088580073 -0.33680824425452 3.95227085160975 -1.73986990399149 2.82395934899507 0.97880785489498 2.43693...
result:
ok
Test #24:
score: 0
Accepted
time: 3ms
memory: 4292kb
input:
1000 1 2 1 3 1 4 1 5 1 6 1 7 1 8 1 9 1 10 1 11 1 12 1 13 1 14 1 15 1 16 1 17 1 18 1 19 1 20 1 21 1 22 1 23 1 24 1 25 1 26 1 27 1 28 1 29 1 30 1 31 2 32 2 33 2 34 2 35 2 36 2 37 2 38 2 39 2 40 2 41 2 42 2 43 2 44 2 45 2 46 2 47 2 48 2 49 2 50 2 51 2 52 2 53 2 54 2 55 2 56 2 57 2 58 2 59 2 60 2 61 3 6...
output:
0.00000000000000 0.00000000000000 0.98784049575328 0.15547075271546 0.93554745106648 0.35320102888160 0.89669286788233 0.44265325107691 0.84930949926305 0.52789523057283 0.79384802637119 0.60811619862208 0.73083596427812 0.68255314321865 0.66087264456847 0.75049806639396 0.58462351487040 0.811304718...
result:
ok
Test #25:
score: 0
Accepted
time: 3ms
memory: 4220kb
input:
1000 328 317 776 347 862 418 328 311 645 81 524 299 814 615 285 907 187 942 678 757 746 877 26 516 846 640 814 456 524 966 135 587 484 873 444 959 923 529 54 888 678 920 444 690 782 314 244 691 648 371 328 350 26 266 413 319 26 583 978 711 285 383 24 956 433 85 746 610 54 437 814 878 436 546 923 781...
output:
0.00000000000000 0.00000000000000 1.58456340054248 3.22613748052809 0.18207591841647 3.99210668018327 1.99643030649730 2.18366663415125 -1.74000177305170 2.97670433188050 -1.24946594505312 3.55760171229713 1.32136354310942 3.50505416852819 0.85883932302764 4.87573064817343 -0.73398132588294 3.858189...
result:
ok
Test #26:
score: 0
Accepted
time: 1ms
memory: 4200kb
input:
1000 1 2 1 3 1 4 1 5 1 6 1 7 1 8 1 9 1 10 1 11 2 12 2 13 2 14 2 15 2 16 2 17 2 18 2 19 2 20 2 21 3 22 3 23 3 24 3 25 3 26 3 27 3 28 3 29 3 30 3 31 4 32 4 33 4 34 4 35 4 36 4 37 4 38 4 39 4 40 4 41 5 42 5 43 5 44 5 45 5 46 5 47 5 48 5 49 5 50 5 51 6 52 6 53 6 54 6 55 6 56 6 57 6 58 6 59 6 60 6 61 7 6...
output:
0.00000000000000 0.00000000000000 0.98480775301221 0.17364817766693 0.86602540378444 0.50000000000000 0.64278760968654 0.76604444311898 0.34202014332567 0.93969262078591 0.00000000000000 1.00000000000000 -0.34202014332567 0.93969262078591 -0.64278760968654 0.76604444311898 -0.86602540378444 0.500000...
result:
ok
Test #27:
score: 0
Accepted
time: 3ms
memory: 4228kb
input:
1000 379 70 15 572 297 546 116 876 382 377 152 208 990 8 547 445 105 320 874 29 105 167 469 57 966 267 11 874 680 689 675 946 67 758 726 438 133 920 612 616 898 852 718 576 818 890 328 684 295 725 219 98 920 944 830 589 11 105 47 231 152 786 353 259 93 547 680 622 47 300 552 767 817 121 949 117 496 ...
output:
0.00000000000000 0.00000000000000 2.67573580591325 4.11441435475924 2.21502626627817 4.88324388752068 0.32615357500572 5.95652200941626 -2.03721784480425 3.51015280294527 1.94100375322773 2.44523329038782 1.97193810008756 2.27687674511565 -2.72880803613545 4.43377512660281 -2.00839890584670 2.033157...
result:
ok
Test #28:
score: 0
Accepted
time: 3ms
memory: 4032kb
input:
1000 1 2 1 3 1 4 2 5 2 6 2 7 3 8 3 9 3 10 4 11 4 12 4 13 5 14 5 15 5 16 6 17 6 18 6 19 7 20 7 21 7 22 8 23 8 24 8 25 9 26 9 27 9 28 10 29 10 30 10 31 11 32 11 33 11 34 12 35 12 36 12 37 13 38 13 39 13 40 14 41 14 42 14 43 15 44 15 45 15 46 16 47 16 48 16 49 17 50 17 51 17 52 18 53 18 54 18 55 19 56 ...
output:
0.00000000000000 0.00000000000000 0.84067431535629 0.54154103768803 -0.14549279846954 0.98935931066196 -0.91051928219144 0.41346660899954 1.82253542133847 0.73114264253209 1.68134863071258 1.08308207537607 1.41927701450024 1.35715057450288 0.08783806638448 1.96175671270830 -0.29098559693909 1.978718...
result:
ok
Test #29:
score: 0
Accepted
time: 4ms
memory: 4196kb
input:
1000 18 101 853 602 290 632 35 998 55 864 920 486 751 806 225 12 679 590 522 403 751 629 711 587 959 929 538 968 145 126 642 340 287 911 847 416 42 533 519 61 885 862 153 409 16 992 815 370 451 33 39 851 551 572 424 838 659 460 112 22 45 665 719 325 73 214 274 711 283 623 920 674 297 729 667 133 878...
output:
0.00000000000000 0.00000000000000 0.46355658237716 10.88336154755260 4.66862098361697 9.98835097534841 -3.40793789227508 8.72089593829858 -1.91773548514969 11.51993096654122 0.17249141704461 10.91063493893019 -1.44151998504192 10.63206747474264 -4.03502337118604 4.23478904373411 -4.10247804815915 7....
result:
ok
Test #30:
score: 0
Accepted
time: 2ms
memory: 4304kb
input:
1000 54 326 815 326 174 54 200 326 107 200 746 107 182 107 287 326 512 182 798 512 131 798 245 131 936 287 724 174 236 174 629 326 339 245 911 512 218 200 868 629 212 218 617 746 940 815 406 936 366 746 145 218 788 107 656 174 413 617 121 245 794 107 45 656 15 131 166 413 673 45 745 794 151 45 60 17...
output:
0.00000000000000 0.00000000000000 7.00135956047034 10.38959817167228 0.99328675907928 6.51394234563147 -0.59713488883875 7.40202148179509 -3.70440976512150 3.36246848927608 -4.92920577842933 8.18764055872249 -3.34980070342429 5.63288424132857 -5.05868022688811 5.15817340643363 -1.77328504298821 2.84...
result:
ok
Test #31:
score: 0
Accepted
time: 1ms
memory: 4156kb
input:
1000 7 9 994 122 143 27 780 619 237 483 374 497 488 374 592 56 838 765 35 1 812 389 512 565 243 847 346 417 69 165 611 802 372 606 334 362 427 687 543 180 143 531 448 750 487 39 790 861 294 534 94 6 12 613 41 222 815 577 19 655 495 553 962 718 534 677 102 74 74 8 626 334 918 193 48 544 2 1 1 11 444 ...
output:
0.00000000000000 0.00000000000000 0.23420142938572 0.97218809418429 -0.93560885088233 0.35303835223760 -0.07777231499780 1.92227881764986 0.78621046240570 1.80602622443761 1.43269706738338 2.56895156127237 -0.98086105952444 0.19470896720127 2.08627463224809 3.32581110352940 -1.94363225823999 0.46502...
result:
ok
Test #32:
score: 0
Accepted
time: 4ms
memory: 4244kb
input:
1000 484 96 142 130 194 415 759 192 312 866 473 948 669 707 121 382 70 659 212 844 123 932 42 672 240 935 133 873 409 11 7 418 115 158 408 38 405 218 714 767 996 530 393 986 737 447 782 439 989 745 723 861 849 466 885 458 895 368 44 200 923 726 670 492 805 726 659 263 76 52 363 823 511 396 475 836 7...
output:
0.00000000000000 0.00000000000000 -2.92520139540915 7.09539159843813 7.66343091598091 10.48202564167168 -2.70220028663223 7.53081655950672 -1.79804374713710 9.63485844522905 -3.12336180458615 8.65357790890600 0.78753124663110 8.84983565284231 1.44409325993792 8.54662040228192 1.09136560925633 8.7345...
result:
ok
Test #33:
score: 0
Accepted
time: 1ms
memory: 4036kb
input:
1000 779 784 64 102 250 235 617 468 966 543 721 87 126 277 896 166 21 782 87 404 637 647 53 630 549 302 658 87 880 87 87 667 495 995 330 460 516 154 993 646 558 87 87 43 304 189 87 1 377 523 846 902 87 725 498 743 87 555 221 87 433 413 808 87 780 87 603 765 256 196 785 804 87 518 187 568 329 86 87 1...
output:
0.00000000000000 0.00000000000000 -0.97538988762726 2.74602822632238 1.91593905314783 1.57369104638640 1.88071033288729 1.68038859761976 0.76189938406503 2.84917635736623 -1.83260101890980 1.80098283720112 -0.87179347575063 1.48987359148931 1.99762749565641 1.09735580175895 -0.01997799941091 2.99990...
result:
ok
Test #34:
score: 0
Accepted
time: 3ms
memory: 4160kb
input:
1000 618 371 516 405 969 986 918 45 582 943 660 464 385 538 458 306 817 223 577 29 551 364 64 714 4 407 149 211 23 281 695 840 823 520 24 702 593 958 348 256 135 444 445 593 706 177 72 894 729 388 557 715 692 176 538 920 827 519 720 136 370 697 617 391 348 566 78 152 617 555 972 29 776 593 856 215 5...
output:
0.00000000000000 0.00000000000000 -5.92239468242377 2.97967679086547 -0.65567873145979 7.81596159130889 -1.98521882409505 5.82003213409686 2.21232950250148 6.32129309819170 -5.89765362119793 3.14653024959721 -0.87945847835236 2.49937271099411 1.32110838848673 4.25738331381832 0.86045707466916 6.9038...
result:
ok
Test #35:
score: 0
Accepted
time: 0ms
memory: 4244kb
input:
1000 648 278 793 733 99 720 309 232 264 783 869 627 599 985 487 790 741 422 109 386 441 227 48 38 526 48 473 82 484 733 33 680 905 145 643 693 155 648 648 417 712 863 150 530 38 692 176 128 790 287 348 720 33 82 22 352 801 790 211 648 369 82 446 733 33 336 657 54 193 33 790 172 25 728 854 366 241 76...
output:
0.00000000000000 0.00000000000000 -1.81128343218016 1.77466475567887 -3.98748620611763 1.31488187742005 1.82564956633077 1.78461485804114 -0.52069561822476 1.85374239274007 1.50627960870905 3.52764457278916 -4.90401605803392 5.95576138664984 -1.82711168021326 1.69165840822209 0.71639198849338 3.9115...
result:
ok
Test #36:
score: 0
Accepted
time: 4ms
memory: 4244kb
input:
1000 814 923 286 969 635 622 257 260 677 969 431 935 969 668 900 366 678 245 402 882 555 431 190 15 389 655 257 981 55 481 55 111 662 570 124 470 222 969 945 757 582 170 47 612 709 431 451 606 15 244 561 463 655 995 670 781 458 99 613 969 781 692 431 719 207 99 222 381 969 402 588 5 66 621 333 321 2...
output:
0.00000000000000 0.00000000000000 -5.95003005607630 7.13071344272065 0.52503016276637 2.84890694162479 -2.20923510376500 3.61294752245885 0.03285545507434 3.72990882786993 2.43530148615286 3.73859530481054 -2.69992768345702 6.06381007207564 1.91941403611079 2.54786022082911 -4.85375604650186 9.48248...
result:
ok
Test #37:
score: 0
Accepted
time: 3ms
memory: 4156kb
input:
1000 966 967 686 699 989 471 513 855 521 583 526 930 67 577 369 186 949 590 927 649 331 302 479 960 30 266 266 45 250 872 298 382 795 825 329 526 64 52 485 972 623 466 529 653 521 76 473 918 461 259 716 139 179 634 981 632 315 710 88 211 275 800 934 137 379 652 124 956 973 233 715 165 578 788 108 53...
output:
0.00000000000000 0.00000000000000 1.86590392875093 6.39378182876134 -5.81050060609551 5.23510442326899 1.87404029696893 4.82344390630202 4.62503461095203 6.02346759691431 -1.88016166680220 11.68209469116634 -4.84301454277119 4.97631043110467 -1.31097663130425 7.70810678516651 1.98126910659337 7.4970...
result:
ok