QOJ.ac
QOJ
ID | Problem | Submitter | Result | Time | Memory | Language | File size | Submit time | Judge time |
---|---|---|---|---|---|---|---|---|---|
#37689 | #1190. Twin Trees Bros | ZhangYiDe | WA | 355ms | 3936kb | C++17 | 5.9kb | 2022-07-02 15:02:39 | 2022-07-02 15:02:40 |
Due to the privacy settings of the submitter, you are not allowed to view this code.
Details
Tip: Click on the bar to expand more detailed information
Test #1:
score: 100
Accepted
time: 2ms
memory: 3832kb
input:
3 0 0 0 1 0 0 3 0 0 1 2 2 3 0 0 0 0 2 2 0 3 3 4 5 5 6
output:
1
result:
ok answer is '1'
Test #2:
score: 0
Accepted
time: 3ms
memory: 3684kb
input:
4 1 0 0 2 0 0 2 1 0 2 -1 0 1 2 2 3 2 4 0 1 1 0 0 0 0 2 0 0 0 2 5 6 5 7 5 8
output:
2
result:
ok answer is '2'
Test #3:
score: 0
Accepted
time: 2ms
memory: 3812kb
input:
3 0 0 0 1 0 0 3 0 0 1 2 2 3 0 0 0 0 2 2 0 3 3 4 5 5 6
output:
1
result:
ok answer is '1'
Test #4:
score: 0
Accepted
time: 2ms
memory: 3820kb
input:
7 5 3 1 5 5 3 5 1 -1 7 5 3 3 5 3 7 1 -1 3 1 -1 1 2 1 3 1 4 1 5 1 6 1 7 13 23 24 10 20 30 10 20 36 10 20 24 13 23 36 7 17 36 7 17 24 8 9 9 10 9 11 9 12 9 13 9 14
output:
4
result:
ok answer is '4'
Test #5:
score: 0
Accepted
time: 2ms
memory: 3848kb
input:
7 5 3 1 5 5 3 5 1 -1 7 5 3 3 5 3 7 1 -1 3 1 -1 1 2 1 3 1 4 1 5 1 6 1 7 13 23 24 13 23 36 10 20 30 10 20 36 10 20 24 7 17 36 7 17 24 8 9 9 10 10 11 10 12 10 13 10 14
output:
0
result:
ok answer is '0'
Test #6:
score: 0
Accepted
time: 2ms
memory: 3804kb
input:
7 5 3 1 5 5 3 5 1 -1 7 5 3 3 5 3 7 1 -1 3 1 -1 1 2 1 3 1 4 1 5 1 6 1 7 13 23 24 10 20 30 10 20 36 10 20 24 13 23 37 7 17 36 7 17 24 8 9 9 10 9 11 9 12 9 13 9 14
output:
0
result:
ok answer is '0'
Test #7:
score: 0
Accepted
time: 2ms
memory: 3808kb
input:
9 134 234 164 185 285 198 134 234 232 185 285 266 134 234 300 185 285 334 134 234 368 185 285 402 134 234 436 1 2 2 3 3 4 4 5 5 6 6 7 7 8 8 9 50 30 278 184 164 680 -84 -104 680 318 298 278 -218 -238 278 452 432 680 -352 -372 680 586 566 278 -486 -506 278 10 11 10 12 11 13 12 14 13 15 14 16 15 17 16 18
output:
2
result:
ok answer is '2'
Test #8:
score: 0
Accepted
time: 0ms
memory: 3752kb
input:
9 185 285 198 134 234 436 185 285 266 185 285 402 134 234 232 134 234 300 134 234 368 134 234 164 185 285 334 1 8 1 5 2 4 3 5 3 6 4 7 6 9 7 9 318 298 278 452 432 680 184 164 680 -218 -238 278 -352 -372 680 586 566 278 -486 -506 278 -84 -104 680 50 30 278 10 12 10 11 11 15 12 18 13 17 13 14 14 16 17 18
output:
2
result:
ok answer is '2'
Test #9:
score: 0
Accepted
time: 2ms
memory: 3748kb
input:
9 185 285 198 134 234 436 185 285 266 185 285 402 134 234 232 134 234 300 134 234 368 134 234 164 185 285 334 1 8 1 5 2 6 3 5 3 6 4 7 6 9 7 9 318 298 278 452 432 680 184 164 680 -218 -238 278 -352 -372 680 586 566 278 -486 -506 278 -84 -104 680 50 30 278 10 12 10 11 11 15 12 18 13 17 13 14 14 16 17 18
output:
0
result:
ok answer is '0'
Test #10:
score: 0
Accepted
time: 2ms
memory: 3876kb
input:
9 185 285 198 134 235 436 185 285 266 185 285 402 134 234 232 134 234 300 134 234 368 134 234 164 185 285 334 1 8 1 5 2 4 3 5 3 6 4 7 6 9 7 9 318 298 278 452 432 680 184 164 680 -218 -238 278 -352 -372 680 586 566 278 -486 -506 278 -84 -104 680 50 30 278 10 12 10 11 11 15 12 18 13 17 13 14 14 16 17 18
output:
0
result:
ok answer is '0'
Test #11:
score: 0
Accepted
time: 1ms
memory: 3860kb
input:
7 -220 520 720 60 240 440 200 100 300 620 -320 -120 -80 380 580 480 -180 20 340 -40 160 1 3 1 7 1 6 1 4 2 3 3 5 230 210 370 50 30 10 170 150 250 -10 -30 -110 -130 -150 -350 110 90 130 -70 -90 -230 8 11 8 9 8 14 8 12 9 10 9 13
output:
1
result:
ok answer is '1'
Test #12:
score: 0
Accepted
time: 2ms
memory: 3772kb
input:
7 -220 520 720 60 240 440 200 100 300 620 -320 -120 -80 380 580 480 -180 20 340 -40 160 1 3 1 7 1 6 2 3 3 5 4 5 230 210 370 50 30 10 170 150 250 -10 -30 -110 -130 -150 -350 110 90 130 -70 -90 -230 8 11 8 9 8 14 8 12 9 10 9 13
output:
0
result:
ok answer is '0'
Test #13:
score: 0
Accepted
time: 2ms
memory: 3808kb
input:
7 -220 520 720 60 240 440 200 100 300 620 -320 -120 -80 380 580 480 -180 20 341 -40 161 1 3 1 7 1 6 1 4 2 3 3 5 230 210 370 50 30 10 170 150 250 -10 -30 -110 -130 -150 -350 110 90 130 -70 -90 -230 8 11 8 9 8 14 8 12 9 10 9 13
output:
0
result:
ok answer is '0'
Test #14:
score: 0
Accepted
time: 2ms
memory: 3688kb
input:
12 -356 -256 92 -356 -256 -12 -356 -256 612 -252 -152 612 -252 -152 508 -252 -152 92 -356 -256 508 -252 -152 196 -252 -152 -12 -252 -152 404 -356 -256 404 -356 -256 196 1 4 2 4 3 11 4 5 4 12 5 11 6 12 7 11 8 12 9 12 10 11 602 582 194 234 214 562 418 398 562 -134 -154 562 234 214 194 -134 -154 194 -3...
output:
1
result:
ok answer is '1'
Test #15:
score: 0
Accepted
time: 2ms
memory: 3804kb
input:
12 -356 -256 92 -356 -256 -12 -356 -256 612 -252 -152 612 -252 -152 508 -252 -152 92 -356 -256 508 -252 -152 196 -252 -152 -12 -252 -152 404 -356 -256 404 -356 -256 196 1 4 2 4 3 11 4 5 4 12 5 11 6 7 7 11 8 12 9 12 10 11 602 582 194 234 214 562 418 398 562 -134 -154 562 234 214 194 -134 -154 194 -31...
output:
0
result:
ok answer is '0'
Test #16:
score: 0
Accepted
time: 2ms
memory: 3808kb
input:
12 -356 -256 92 -356 -256 -12 -356 -256 612 -252 -152 612 -252 -152 508 -252 -152 93 -356 -256 508 -252 -152 196 -252 -152 -12 -252 -152 404 -356 -256 404 -356 -256 196 1 4 2 4 3 11 4 5 4 12 5 11 6 12 7 11 8 12 9 12 10 11 418 398 562 -502 -522 562 -134 -154 194 234 214 562 -502 -522 194 602 582 562 ...
output:
0
result:
ok answer is '0'
Test #17:
score: 0
Accepted
time: 2ms
memory: 3868kb
input:
4 -500 -400 360 -500 -400 240 100 200 240 100 200 360 1 2 2 4 3 4 890 114 94 -790 114 94 890 -54 -74 -790 -54 -74 5 8 5 7 6 8
output:
2
result:
ok answer is '2'
Test #18:
score: 0
Accepted
time: 2ms
memory: 3828kb
input:
4 -500 -400 360 -500 -400 240 100 200 240 100 200 360 1 2 2 4 3 4 890 114 94 890 -54 -74 -790 114 94 -790 -54 -74 5 8 6 7 7 8
output:
0
result:
ok answer is '0'
Test #19:
score: 0
Accepted
time: 0ms
memory: 3828kb
input:
4 -500 -400 360 -500 -400 240 100 200 240 100 200 360 1 2 2 4 3 4 -790 114 94 890 -54 -75 890 114 94 -790 -54 -74 5 8 6 7 7 8
output:
0
result:
ok answer is '0'
Test #20:
score: 0
Accepted
time: 2ms
memory: 3828kb
input:
4 1 0 0 2 0 0 2 1 0 2 -1 0 1 2 2 3 2 4 0 1 1 0 0 0 0 2 0 0 0 2 5 6 5 7 5 8
output:
2
result:
ok answer is '2'
Test #21:
score: 0
Accepted
time: 355ms
memory: 3924kb
input:
199 -175 -10 195 -95 -125 390 -110 25 310 -105 -170 360 -145 -60 205 -340 -75 315 -305 -10 275 -245 -5 230 -175 5 390 -295 -40 230 -235 -90 205 -290 -225 310 -130 -5 360 -105 -45 260 -95 -190 275 -105 -30 345 -240 -5 355 -90 -15 365 -295 -155 260 -285 -165 410 -245 -195 370 -225 -115 160 -235 -195 2...
output:
24
result:
ok answer is '24'
Test #22:
score: 0
Accepted
time: 0ms
memory: 3704kb
input:
199 -175 -10 195 -95 -125 390 -110 25 310 -105 -170 360 -145 -60 205 -340 -75 315 -305 -10 275 -245 -5 230 -175 5 390 -295 -40 230 -235 -90 205 -290 -225 310 -130 -5 360 -105 -45 260 -95 -190 275 -105 -30 345 -240 -5 355 -90 -15 365 -295 -155 260 -285 -165 410 -245 -195 370 -225 -115 160 -235 -195 2...
output:
0
result:
ok answer is '0'
Test #23:
score: 0
Accepted
time: 355ms
memory: 3840kb
input:
199 -175 -10 195 -95 -125 390 -110 25 310 -105 -170 360 -145 -60 205 -340 -75 315 -305 -10 275 -245 -5 230 -175 5 390 -295 -40 230 -235 -90 205 -290 -225 310 -130 -5 360 -105 -45 260 -95 -190 275 -105 -30 345 -240 -5 355 -90 -15 365 -295 -155 260 -285 -165 410 -245 -195 370 -225 -115 160 -235 -195 2...
output:
0
result:
ok answer is '0'
Test #24:
score: 0
Accepted
time: 197ms
memory: 3936kb
input:
165 -170 -94 357 -221 -121 384 -191 -55 294 -143 -139 309 -158 -106 351 -161 -184 267 -146 -178 282 -209 -43 339 -158 -181 264 -149 -157 285 -179 -184 321 -215 -151 357 -209 -55 306 -239 -16 267 -185 -43 249 -221 -16 321 -209 -145 294 -233 -16 339 -248 -148 213 -194 -70 243 -242 -19 264 -179 -16 279...
output:
8
result:
ok answer is '8'
Test #25:
score: 0
Accepted
time: 2ms
memory: 3756kb
input:
165 -170 -94 357 -221 -121 384 -191 -55 294 -143 -139 309 -158 -106 351 -161 -184 267 -146 -178 282 -209 -43 339 -158 -181 264 -149 -157 285 -179 -184 321 -215 -151 357 -209 -55 306 -239 -16 267 -185 -43 249 -221 -16 321 -209 -145 294 -233 -16 339 -248 -148 213 -194 -70 243 -242 -19 264 -179 -16 279...
output:
0
result:
ok answer is '0'
Test #26:
score: 0
Accepted
time: 196ms
memory: 3780kb
input:
165 -170 -94 357 -221 -121 384 -191 -55 294 -143 -139 309 -158 -106 351 -161 -184 267 -146 -178 282 -209 -43 339 -158 -181 264 -149 -157 285 -179 -184 321 -215 -151 357 -209 -55 306 -239 -16 267 -185 -43 249 -221 -16 321 -209 -145 294 -233 -16 339 -248 -148 213 -194 -70 243 -242 -19 264 -179 -16 279...
output:
0
result:
ok answer is '0'
Test #27:
score: 0
Accepted
time: 197ms
memory: 3876kb
input:
165 -248 -58 384 -221 -139 261 -239 -121 261 -116 -58 348 -239 -88 234 -239 -106 345 -125 -151 279 -230 -121 339 -146 -55 285 -149 -109 249 -221 -61 339 -179 -49 225 -239 -115 333 -254 -85 255 -239 -133 285 -284 -148 258 -167 -115 339 -251 -49 291 -170 -121 261 -248 -142 216 -245 -94 339 -266 -112 2...
output:
4
result:
ok answer is '4'
Test #28:
score: 0
Accepted
time: 198ms
memory: 3732kb
input:
165 -248 -58 384 -221 -139 261 -239 -121 261 -116 -58 348 -239 -88 234 -239 -106 345 -125 -151 279 -230 -121 339 -146 -55 285 -149 -109 249 -221 -61 339 -179 -49 225 -239 -115 333 -254 -85 255 -239 -133 285 -284 -148 258 -167 -115 339 -251 -49 291 -170 -121 261 -248 -142 216 -245 -94 339 -266 -112 2...
output:
0
result:
ok answer is '0'
Test #29:
score: 0
Accepted
time: 195ms
memory: 3784kb
input:
165 -248 -58 384 -221 -139 261 -239 -121 261 -116 -58 348 -239 -88 234 -239 -106 345 -125 -151 279 -230 -121 339 -146 -55 285 -149 -109 249 -221 -61 339 -179 -49 225 -239 -115 333 -254 -85 255 -239 -133 285 -284 -148 258 -167 -115 339 -251 -49 291 -170 -121 261 -248 -142 216 -245 -94 339 -266 -112 2...
output:
0
result:
ok answer is '0'
Test #30:
score: 0
Accepted
time: 15ms
memory: 3836kb
input:
67 -39 -16 321 -277 -142 307 -39 -121 384 -396 -30 405 -312 -219 272 -4 -30 195 -361 -16 279 -270 -100 300 -305 5 328 -95 5 272 -361 -121 216 -95 -128 195 -88 19 272 -396 -170 195 -116 -184 412 -361 -79 384 -88 -79 384 -95 -72 405 -116 -16 188 -130 -100 300 -361 -184 321 -312 19 328 -312 -184 279 -4...
output:
8
result:
ok answer is '8'
Test #31:
score: 0
Accepted
time: 2ms
memory: 3748kb
input:
67 -39 -16 321 -277 -142 307 -39 -121 384 -396 -30 405 -312 -219 272 -4 -30 195 -361 -16 279 -270 -100 300 -305 5 328 -95 5 272 -361 -121 216 -95 -128 195 -88 19 272 -396 -170 195 -116 -184 412 -361 -79 384 -88 -79 384 -95 -72 405 -116 -16 188 -130 -100 300 -361 -184 321 -312 19 328 -312 -184 279 -4...
output:
0
result:
ok answer is '0'
Test #32:
score: 0
Accepted
time: 11ms
memory: 3816kb
input:
67 -39 -16 321 -277 -142 307 -39 -121 384 -396 -30 405 -312 -219 272 -4 -30 195 -361 -16 279 -270 -100 300 -305 5 328 -95 5 272 -361 -121 216 -95 -128 195 -88 19 272 -396 -170 195 -116 -184 412 -361 -79 384 -88 -79 384 -95 -72 405 -116 -16 188 -130 -100 300 -361 -184 321 -312 19 328 -312 -184 279 -4...
output:
0
result:
ok answer is '0'
Test #33:
score: 0
Accepted
time: 25ms
memory: 3896kb
input:
83 -81 -51 125 -242 -191 181 -123 -128 391 -109 -219 125 -326 -198 503 -81 -191 475 -277 -79 146 -144 26 426 -291 -142 419 -109 -58 419 -165 -191 97 -109 -135 503 -123 -121 146 -81 -149 475 -277 -121 454 -193 -135 216 -81 -9 125 -193 -65 384 -249 19 125 -109 -65 97 -291 -219 475 -235 -191 503 -123 -...
output:
2
result:
ok answer is '2'
Test #34:
score: 0
Accepted
time: 2ms
memory: 3820kb
input:
83 -81 -51 125 -242 -191 181 -123 -128 391 -109 -219 125 -326 -198 503 -81 -191 475 -277 -79 146 -144 26 426 -291 -142 419 -109 -58 419 -165 -191 97 -109 -135 503 -123 -121 146 -81 -149 475 -277 -121 454 -193 -135 216 -81 -9 125 -193 -65 384 -249 19 125 -109 -65 97 -291 -219 475 -235 -191 503 -123 -...
output:
0
result:
ok answer is '0'
Test #35:
score: 0
Accepted
time: 26ms
memory: 3884kb
input:
83 -81 -51 125 -242 -191 181 -123 -128 391 -109 -219 125 -326 -198 503 -81 -191 475 -277 -79 146 -144 26 426 -291 -142 419 -109 -58 419 -165 -191 97 -109 -135 503 -123 -121 146 -81 -149 475 -277 -121 454 -193 -135 216 -81 -9 125 -193 -65 384 -249 19 125 -109 -65 97 -291 -219 475 -235 -191 503 -123 -...
output:
0
result:
ok answer is '0'
Test #36:
score: 0
Accepted
time: 26ms
memory: 3820kb
input:
83 -102 -142 321 -81 -156 167 -298 -142 279 -102 -163 174 3 -65 174 -326 -44 195 -123 -198 216 -291 19 286 -109 -114 419 -81 33 244 3 -226 265 -354 -16 265 -123 -2 384 -403 -135 174 -277 -16 398 -74 -156 195 3 26 335 -319 -233 244 -277 -198 384 -81 -44 433 -102 26 237 -74 -205 356 -46 -121 321 -291 ...
output:
2
result:
ok answer is '2'
Test #37:
score: 0
Accepted
time: 1ms
memory: 3748kb
input:
83 -102 -142 321 -81 -156 167 -298 -142 279 -102 -163 174 3 -65 174 -326 -44 195 -123 -198 216 -291 19 286 -109 -114 419 -81 33 244 3 -226 265 -354 -16 265 -123 -2 384 -403 -135 174 -277 -16 398 -74 -156 195 3 26 335 -319 -233 244 -277 -198 384 -81 -44 433 -102 26 237 -74 -205 356 -46 -121 321 -291 ...
output:
0
result:
ok answer is '0'
Test #38:
score: 0
Accepted
time: 18ms
memory: 3804kb
input:
83 -102 -142 321 -81 -156 167 -298 -142 279 -102 -163 174 3 -65 174 -326 -44 195 -123 -198 216 -291 19 286 -109 -114 419 -81 33 244 3 -226 265 -354 -16 265 -123 -2 384 -403 -135 174 -277 -16 398 -74 -156 195 3 26 335 -319 -233 244 -277 -198 384 -81 -44 433 -102 26 237 -74 -205 356 -46 -121 321 -291 ...
output:
0
result:
ok answer is '0'
Test #39:
score: 0
Accepted
time: 26ms
memory: 3832kb
input:
83 -92 50 106 -4 82 -34 96 -70 66 92 -82 -14 56 50 102 40 -26 82 -8 66 10 24 -70 98 44 82 46 92 62 74 52 50 -46 24 58 90 -40 66 18 52 -70 -22 -64 102 -42 32 50 14 -80 62 82 24 -78 -30 56 10 18 -84 82 14 40 42 46 32 62 90 24 102 102 -52 98 -22 48 14 102 40 62 -22 -4 50 82 16 106 -30 -88 34 90 20 -10 ...
output:
2
result:
ok answer is '2'
Test #40:
score: 0
Accepted
time: 2ms
memory: 3864kb
input:
83 -92 50 106 -4 82 -34 96 -70 66 92 -82 -14 56 50 102 40 -26 82 -8 66 10 24 -70 98 44 82 46 92 62 74 52 50 -46 24 58 90 -40 66 18 52 -70 -22 -64 102 -42 32 50 14 -80 62 82 24 -78 -30 56 10 18 -84 82 14 40 42 46 32 62 90 24 102 102 -52 98 -22 48 14 102 40 62 -22 -4 50 82 16 106 -30 -88 34 90 20 -10 ...
output:
0
result:
ok answer is '0'
Test #41:
score: 0
Accepted
time: 25ms
memory: 3816kb
input:
83 -92 50 106 -4 82 -34 96 -70 66 92 -82 -14 56 50 102 40 -26 82 -8 66 10 24 -70 98 44 82 46 92 62 74 52 50 -46 24 58 90 -40 66 18 52 -70 -22 -64 102 -42 32 50 14 -80 62 82 24 -78 -30 56 10 18 -84 82 14 40 42 46 32 62 90 24 102 102 -52 98 -22 48 14 102 40 62 -22 -4 50 82 16 106 -30 -88 34 90 20 -10 ...
output:
0
result:
ok answer is '0'
Test #42:
score: 0
Accepted
time: 306ms
memory: 3828kb
input:
200 139 5 8 -17 5 8 231 5 8 135 5 8 -201 5 8 -377 5 8 79 5 8 123 5 8 235 5 8 -57 5 8 -225 5 8 -361 5 8 -161 5 8 -373 5 8 -129 5 8 23 5 8 -177 5 8 -65 5 8 -77 5 8 -353 5 8 267 5 8 -69 5 8 147 5 8 227 5 8 351 5 8 -305 5 8 -1 5 8 -165 5 8 55 5 8 -257 5 8 263 5 8 -121 5 8 -221 5 8 -249 5 8 159 5 8 67 5 ...
output:
1
result:
ok answer is '1'
Test #43:
score: 0
Accepted
time: 3ms
memory: 3916kb
input:
200 139 5 8 -17 5 8 231 5 8 135 5 8 -201 5 8 -377 5 8 79 5 8 123 5 8 235 5 8 -57 5 8 -225 5 8 -361 5 8 -161 5 8 -373 5 8 -129 5 8 23 5 8 -177 5 8 -65 5 8 -77 5 8 -353 5 8 267 5 8 -69 5 8 147 5 8 227 5 8 351 5 8 -305 5 8 -1 5 8 -165 5 8 55 5 8 -257 5 8 263 5 8 -121 5 8 -221 5 8 -249 5 8 159 5 8 67 5 ...
output:
0
result:
ok answer is '0'
Test #44:
score: -100
Wrong Answer
time: 307ms
memory: 3736kb
input:
200 139 5 8 -17 5 8 231 5 8 135 5 8 -201 5 8 -377 5 8 79 5 8 123 5 8 235 5 8 -57 5 8 -225 5 8 -361 5 8 -161 5 8 -373 5 8 -129 5 8 23 5 8 -177 5 8 -65 5 8 -77 5 8 -353 5 8 267 5 8 -69 5 8 147 5 8 227 5 8 351 5 8 -305 5 8 -1 5 8 -165 5 8 55 5 8 -257 5 8 263 5 8 -121 5 8 -221 5 8 -249 5 8 159 5 8 67 5 ...
output:
1
result:
wrong answer expected '0', found '1'