QOJ.ac
QOJ
ID | Problem | Submitter | Result | Time | Memory | Language | File size | Submit time | Judge time |
---|---|---|---|---|---|---|---|---|---|
#659834 | #9490. Sub Brackets | ucup-team5055# | AC ✓ | 1ms | 4048kb | C++17 | 1.5kb | 2024-10-19 22:22:17 | 2024-10-19 22:22:18 |
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: 1ms
memory: 3668kb
input:
5 3 1 2 4 5 2 5
output:
2
result:
ok "2"
Test #2:
score: 0
Accepted
time: 0ms
memory: 3644kb
input:
2 4 1 2 1 2 1 2 1 2
output:
4
result:
ok "4"
Test #3:
score: 0
Accepted
time: 0ms
memory: 3568kb
input:
32 11 25 32 19 32 11 24 20 31 22 25 21 26 17 22 30 31 23 28 4 15 19 22
output:
8
result:
ok "8"
Test #4:
score: 0
Accepted
time: 1ms
memory: 3832kb
input:
499 500 162 343 318 339 57 480 390 409 35 390 244 355 86 245 65 130 239 386 208 219 63 444 366 419 393 420 169 390 219 446 491 494 235 498 205 328 380 483 485 490 243 448 467 488 10 249 339 470 332 465 38 469 359 430 378 465 447 490 414 461 347 476 197 360 111 122 209 460 3 364 445 470 212 337 495 4...
output:
264
result:
ok "264"
Test #5:
score: 0
Accepted
time: 0ms
memory: 3916kb
input:
500 500 171 410 142 433 337 392 158 205 290 373 148 315 414 465 344 381 86 103 221 466 42 315 242 433 281 344 85 268 442 469 60 415 436 461 345 378 343 488 276 443 102 409 475 496 281 352 286 439 306 477 365 464 331 462 287 296 245 266 164 213 305 474 280 495 257 478 182 321 119 166 3 270 338 401 20...
output:
253
result:
ok "253"
Test #6:
score: 0
Accepted
time: 1ms
memory: 3900kb
input:
499 500 482 497 321 398 286 321 489 494 167 178 296 401 146 373 98 145 232 375 67 376 243 478 354 401 212 393 82 185 385 486 494 495 418 491 296 403 47 492 482 485 131 278 1 104 409 484 403 436 402 461 233 498 243 332 486 497 233 264 353 372 82 455 465 478 218 441 220 395 387 416 394 487 341 412 330...
output:
256
result:
ok "256"
Test #7:
score: 0
Accepted
time: 0ms
memory: 3872kb
input:
499 499 322 433 115 244 492 495 268 389 164 489 352 467 207 436 292 465 63 106 411 460 173 376 479 486 300 479 360 395 415 438 4 391 465 476 349 416 44 111 236 483 294 365 447 456 163 498 323 418 364 379 377 482 294 489 455 494 347 434 267 316 204 443 217 440 85 482 81 128 320 459 108 371 171 422 48...
output:
262
result:
ok "262"
Test #8:
score: 0
Accepted
time: 1ms
memory: 3876kb
input:
500 499 435 468 89 328 194 425 187 286 295 420 418 445 467 496 71 490 246 463 423 460 283 444 421 442 333 416 68 345 354 423 38 211 358 397 182 385 148 487 131 498 311 364 40 351 421 438 438 471 413 448 319 344 450 479 228 385 309 328 149 448 110 291 408 455 131 470 334 485 346 397 254 435 480 489 6...
output:
253
result:
ok "253"
Test #9:
score: 0
Accepted
time: 1ms
memory: 3832kb
input:
499 499 471 486 407 466 38 341 357 396 376 487 367 372 463 472 182 187 245 456 314 495 42 217 16 243 186 357 478 487 477 488 179 338 113 222 72 459 271 280 233 240 486 489 253 356 424 437 206 369 12 319 254 333 208 383 272 395 473 474 154 473 141 202 317 494 242 487 280 333 137 368 484 485 462 467 9...
output:
266
result:
ok "266"
Test #10:
score: 0
Accepted
time: 1ms
memory: 3928kb
input:
500 499 241 358 473 482 483 490 120 355 470 495 16 267 473 478 137 144 50 289 197 356 479 500 212 297 420 427 239 390 380 399 210 321 256 303 256 287 11 294 369 470 480 489 114 415 455 462 451 480 272 337 281 362 143 212 43 290 395 426 156 257 469 496 160 461 147 198 246 255 22 111 371 420 39 454 25...
output:
261
result:
ok "261"
Test #11:
score: 0
Accepted
time: 1ms
memory: 4036kb
input:
500 499 460 475 106 201 149 462 449 470 478 499 33 284 463 468 335 470 101 338 192 277 14 477 127 132 31 262 483 498 79 236 141 372 277 308 80 433 37 212 50 397 177 322 43 64 109 340 485 494 60 269 160 233 27 496 117 318 196 201 133 368 473 480 230 237 115 292 340 447 87 258 131 368 177 296 497 498 ...
output:
260
result:
ok "260"
Test #12:
score: 0
Accepted
time: 1ms
memory: 4040kb
input:
499 500 118 391 319 446 291 498 165 334 401 462 23 216 241 372 248 301 280 427 355 450 295 476 238 283 222 411 297 416 365 394 477 478 283 320 32 85 341 424 238 303 109 314 260 421 15 376 30 349 258 365 426 473 331 394 249 482 110 269 11 190 385 462 137 280 391 498 454 477 365 488 441 498 343 474 14...
output:
254
result:
ok "254"
Test #13:
score: 0
Accepted
time: 1ms
memory: 3840kb
input:
500 500 253 414 308 407 340 443 305 378 395 456 32 87 199 446 261 450 304 459 87 338 48 227 25 276 8 221 457 494 402 491 53 308 248 265 18 315 467 492 385 490 69 274 6 175 77 192 179 320 46 379 450 457 263 470 171 330 461 466 297 430 41 112 314 373 337 440 316 385 325 408 242 331 222 449 374 469 395...
output:
261
result:
ok "261"
Test #14:
score: 0
Accepted
time: 1ms
memory: 3664kb
input:
375 309 357 370 68 317 20 99 311 370 55 102 6 37 327 328 373 374 217 334 80 237 25 74 332 345 311 348 252 323 85 244 255 282 345 368 31 188 360 373 193 238 70 85 25 198 275 354 204 249 88 353 101 310 311 354 2 251 133 188 355 372 227 230 304 343 83 180 138 141 366 371 183 236 233 338 249 282 119 202...
output:
166
result:
ok "166"
Test #15:
score: 0
Accepted
time: 1ms
memory: 3748kb
input:
351 347 343 350 110 197 91 144 144 193 7 68 177 328 179 262 285 336 14 349 67 260 334 347 278 287 302 345 332 351 238 267 190 289 284 289 36 269 230 239 195 214 302 307 171 294 28 349 54 341 229 288 133 218 69 336 245 294 113 220 254 335 340 341 210 237 38 93 118 185 13 200 262 273 330 337 63 304 24...
output:
181
result:
ok "181"
Test #16:
score: 0
Accepted
time: 1ms
memory: 3752kb
input:
475 348 422 435 349 386 222 289 43 68 138 251 47 202 72 137 345 400 139 436 204 461 63 392 269 312 359 382 13 434 304 435 166 425 302 465 133 176 107 200 71 430 322 391 115 318 80 457 356 437 240 455 87 260 14 405 214 413 321 424 36 143 453 456 258 327 311 378 290 327 102 245 329 428 82 219 113 282 ...
output:
181
result:
ok "181"
Test #17:
score: 0
Accepted
time: 1ms
memory: 3744kb
input:
466 436 205 330 98 241 291 462 289 384 296 373 292 347 38 191 344 451 62 207 233 358 308 435 299 430 246 441 430 447 454 461 266 417 253 452 332 335 63 148 87 234 445 464 201 262 92 203 429 452 393 420 337 344 305 326 69 182 84 441 392 423 350 381 108 153 79 252 165 204 49 190 309 444 278 465 346 36...
output:
234
result:
ok "234"
Test #18:
score: 0
Accepted
time: 1ms
memory: 3708kb
input:
331 247 48 197 224 291 252 307 185 316 101 226 155 184 283 312 199 318 275 298 172 223 3 166 15 300 255 296 269 270 38 223 225 300 22 203 33 240 325 330 121 278 320 329 8 327 202 207 174 281 230 253 318 321 128 209 147 268 120 157 237 308 12 79 131 304 330 331 113 258 230 255 168 229 99 138 70 159 1...
output:
125
result:
ok "125"
Test #19:
score: 0
Accepted
time: 1ms
memory: 3832kb
input:
118 229 61 114 104 107 82 107 25 100 49 52 40 75 74 85 95 110 68 101 28 51 13 100 59 106 92 115 90 99 17 84 81 102 84 101 64 107 50 109 105 118 61 94 41 64 50 113 16 33 40 45 88 111 117 118 27 74 75 112 5 8 100 101 54 91 42 105 15 32 111 116 97 104 37 114 95 110 11 102 111 116 73 74 83 92 42 85 21 4...
output:
126
result:
ok "126"
Test #20:
score: 0
Accepted
time: 1ms
memory: 3936kb
input:
399 354 130 279 317 398 239 266 395 398 108 373 327 344 248 299 52 253 151 318 140 317 93 154 106 151 334 353 24 101 187 300 34 67 291 364 167 322 74 299 154 159 154 325 278 335 22 157 37 108 386 393 271 352 157 214 35 108 109 344 207 308 195 338 367 392 316 335 370 399 301 394 41 354 93 250 274 367...
output:
180
result:
ok "180"
Test #21:
score: 0
Accepted
time: 1ms
memory: 3744kb
input:
103 224 93 102 37 92 44 47 46 69 23 46 11 30 97 102 90 103 82 103 35 42 43 102 27 72 76 95 69 102 75 84 32 71 27 50 72 97 75 84 93 96 42 57 83 94 21 50 33 58 19 34 58 97 55 94 29 38 18 75 81 102 2 15 30 79 30 43 55 96 69 84 88 101 69 70 74 91 8 55 93 100 98 101 10 97 61 78 2 83 97 102 92 99 81 84 14...
output:
123
result:
ok "123"
Test #22:
score: 0
Accepted
time: 1ms
memory: 3684kb
input:
305 235 217 290 152 159 23 182 26 195 204 267 230 271 93 214 46 287 10 179 11 180 201 226 34 61 213 258 282 291 4 279 231 294 31 196 253 304 116 151 193 228 100 101 11 194 18 191 111 304 10 45 289 304 24 71 37 272 175 276 114 211 257 258 112 135 246 261 207 252 158 255 212 219 257 304 274 281 269 30...
output:
121
result:
ok "121"
Test #23:
score: 0
Accepted
time: 1ms
memory: 3800kb
input:
109 410 82 99 55 62 75 90 58 79 4 17 63 78 8 33 70 97 29 74 43 98 45 104 96 99 27 108 83 96 82 95 70 107 56 79 93 104 21 92 42 81 97 102 1 58 86 89 38 91 82 89 33 82 63 70 19 66 77 106 36 63 35 46 55 66 34 73 83 100 66 85 36 81 36 53 12 55 10 31 25 28 90 109 83 100 86 107 37 98 56 87 8 105 42 101 11...
output:
207
result:
ok "207"
Test #24:
score: 0
Accepted
time: 1ms
memory: 3992kb
input:
247 478 186 247 61 196 88 129 198 243 49 178 145 242 231 238 35 50 176 191 26 97 60 99 181 216 100 217 54 193 61 246 144 165 233 242 20 85 158 191 196 227 200 245 106 187 3 88 7 224 201 240 200 247 14 141 200 245 108 133 46 119 186 217 197 230 98 145 177 230 9 78 129 184 67 140 181 246 221 236 48 21...
output:
246
result:
ok "246"
Test #25:
score: 0
Accepted
time: 1ms
memory: 3720kb
input:
222 208 2 177 118 205 149 218 168 171 220 221 12 41 153 218 95 214 178 217 14 27 159 202 53 222 48 211 187 222 116 147 57 178 71 72 132 183 110 189 17 192 101 172 120 215 122 155 115 172 121 220 90 143 55 108 43 212 108 141 128 181 217 220 121 194 164 175 24 103 110 119 85 90 143 208 92 117 35 176 9...
output:
110
result:
ok "110"
Test #26:
score: 0
Accepted
time: 1ms
memory: 4048kb
input:
274 489 128 265 147 248 152 249 198 243 211 254 209 212 155 160 46 177 10 209 5 204 236 241 90 217 115 236 268 269 19 216 81 238 221 250 84 111 166 187 54 155 75 234 268 273 99 150 44 127 51 114 52 235 251 258 168 267 242 255 254 263 55 154 124 273 213 234 90 219 137 212 203 228 251 272 46 71 51 274...
output:
261
result:
ok "261"
Test #27:
score: 0
Accepted
time: 0ms
memory: 3652kb
input:
385 78 304 335 176 307 235 302 17 154 164 277 192 285 382 385 127 226 368 381 356 359 346 375 194 347 337 358 196 211 25 192 132 185 201 354 336 357 335 360 351 378 258 275 370 385 169 268 102 269 326 385 78 113 25 28 359 370 275 306 315 368 382 385 340 353 290 299 313 374 158 185 189 224 319 372 19...
output:
43
result:
ok "43"
Test #28:
score: 0
Accepted
time: 1ms
memory: 3840kb
input:
93 475 57 76 73 76 63 76 74 75 85 92 91 92 49 54 85 92 76 81 82 85 53 92 3 86 5 32 68 93 3 38 76 91 31 76 43 90 89 90 61 88 23 66 92 93 22 83 13 14 33 92 16 31 87 90 50 57 86 93 61 88 5 56 86 91 38 71 80 89 46 47 75 82 52 87 15 50 77 86 40 79 18 33 38 91 38 87 14 39 40 83 51 60 1 48 61 92 40 53 28 9...
output:
242
result:
ok "242"
Test #29:
score: 0
Accepted
time: 1ms
memory: 3800kb
input:
296 443 84 161 136 201 87 134 186 249 152 209 36 155 284 295 180 291 147 266 239 248 12 203 45 134 163 166 210 277 77 126 106 251 41 296 38 67 220 281 41 284 257 284 8 167 291 296 83 96 166 183 138 269 136 145 131 170 18 181 223 254 131 146 73 110 173 284 110 279 135 150 216 239 204 215 8 197 32 169...
output:
239
result:
ok "239"
Test #30:
score: 0
Accepted
time: 1ms
memory: 3940kb
input:
87 295 56 67 78 85 78 83 52 87 26 61 81 86 5 42 31 36 6 57 30 77 48 73 30 77 76 85 66 85 76 81 14 55 26 39 74 83 75 86 83 86 75 86 40 47 27 56 21 24 85 86 6 17 65 66 50 79 33 36 44 71 42 67 48 83 75 78 40 49 54 81 18 41 55 68 70 87 85 86 45 46 86 87 21 46 69 86 86 87 16 41 10 57 53 54 74 81 57 66 25...
output:
160
result:
ok "160"
Test #31:
score: 0
Accepted
time: 1ms
memory: 3792kb
input:
177 394 127 136 87 168 15 134 23 82 31 118 160 169 140 169 13 118 101 120 139 154 176 177 54 113 94 111 14 79 34 51 52 113 152 171 62 161 58 129 20 61 141 142 80 147 93 128 64 113 59 176 145 154 36 153 62 161 60 133 102 115 75 106 103 118 58 99 164 169 169 176 128 131 65 120 95 142 28 143 30 115 158...
output:
207
result:
ok "207"
Test #32:
score: 0
Accepted
time: 1ms
memory: 3740kb
input:
482 216 133 162 280 423 234 317 139 416 289 464 419 440 409 428 153 306 84 219 22 93 272 381 397 470 369 408 432 479 198 269 89 352 447 452 139 272 135 294 63 90 448 465 387 404 70 339 185 450 236 327 235 350 148 455 193 440 352 463 401 456 403 428 25 420 427 472 71 306 325 400 360 479 351 436 377 3...
output:
128
result:
ok "128"
Test #33:
score: 0
Accepted
time: 0ms
memory: 3744kb
input:
411 190 115 340 368 399 170 383 310 313 169 334 68 255 23 270 356 377 218 279 112 265 194 317 130 261 258 345 176 411 154 401 189 268 76 327 83 160 242 399 345 402 61 126 235 384 345 390 83 356 46 157 83 160 348 351 14 341 22 107 258 307 95 292 9 270 400 403 215 348 273 328 372 379 133 146 366 367 2...
output:
101
result:
ok "101"
Test #34:
score: 0
Accepted
time: 0ms
memory: 3792kb
input:
500 250 1 500 2 499 3 498 4 497 5 496 6 495 7 494 8 493 9 492 10 491 11 490 12 489 13 488 14 487 15 486 16 485 17 484 18 483 19 482 20 481 21 480 22 479 23 478 24 477 25 476 26 475 27 474 28 473 29 472 30 471 31 470 32 469 33 468 34 467 35 466 36 465 37 464 38 463 39 462 40 461 41 460 42 459 43 458 ...
output:
250
result:
ok "250"
Test #35:
score: 0
Accepted
time: 1ms
memory: 3968kb
input:
500 250 1 250 2 251 3 252 4 253 5 254 6 255 7 256 8 257 9 258 10 259 11 260 12 261 13 262 14 263 15 264 16 265 17 266 18 267 19 268 20 269 21 270 22 271 23 272 24 273 25 274 26 275 27 276 28 277 29 278 30 279 31 280 32 281 33 282 34 283 35 284 36 285 37 286 38 287 39 288 40 289 41 290 42 291 43 292 ...
output:
125
result:
ok "125"
Test #36:
score: 0
Accepted
time: 1ms
memory: 3844kb
input:
44 484 1 2 1 4 1 6 1 8 1 10 1 12 1 14 1 16 1 18 1 20 1 22 1 24 1 26 1 28 1 30 1 32 1 34 1 36 1 38 1 40 1 42 1 44 2 3 2 5 2 7 2 9 2 11 2 13 2 15 2 17 2 19 2 21 2 23 2 25 2 27 2 29 2 31 2 33 2 35 2 37 2 39 2 41 2 43 3 4 3 6 3 8 3 10 3 12 3 14 3 16 3 18 3 20 3 22 3 24 3 26 3 28 3 30 3 32 3 34 3 36 3 38...
output:
253
result:
ok "253"
Test #37:
score: 0
Accepted
time: 1ms
memory: 3684kb
input:
500 499 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 ...
output:
250
result:
ok "250"
Test #38:
score: 0
Accepted
time: 1ms
memory: 3620kb
input:
500 497 1 4 2 5 3 6 4 7 5 8 6 9 7 10 8 11 9 12 10 13 11 14 12 15 13 16 14 17 15 18 16 19 17 20 18 21 19 22 20 23 21 24 22 25 23 26 24 27 25 28 26 29 27 30 28 31 29 32 30 33 31 34 32 35 33 36 34 37 35 38 36 39 37 40 38 41 39 42 40 43 41 44 42 45 43 46 44 47 45 48 46 49 47 50 48 51 49 52 50 53 51 54 5...
output:
249
result:
ok "249"
Test #39:
score: 0
Accepted
time: 0ms
memory: 3828kb
input:
43 19 25 36 3 30 10 27 18 43 39 42 34 39 25 42 3 26 2 9 11 20 40 41 39 42 9 42 32 41 36 39 17 24 15 36 31 38 37 40
output:
12
result:
ok "12"
Test #40:
score: 0
Accepted
time: 0ms
memory: 3856kb
input:
48 27 46 47 33 40 4 37 34 47 11 48 23 28 14 47 18 35 28 47 38 45 17 34 22 35 9 18 12 17 12 23 7 42 36 45 38 47 17 30 26 45 39 42 33 48 31 44 38 41 23 30 11 12 15 28
output:
14
result:
ok "14"
Test #41:
score: 0
Accepted
time: 0ms
memory: 3612kb
input:
45 27 20 43 32 39 43 44 36 45 25 28 30 33 11 32 25 44 7 38 24 25 13 26 30 45 43 44 5 34 9 20 38 41 43 44 19 42 18 25 24 37 31 40 37 38 16 41 5 38 1 24 22 29 10 15
output:
15
result:
ok "15"
Test #42:
score: 0
Accepted
time: 0ms
memory: 3640kb
input:
36 40 33 34 10 31 23 30 8 33 7 14 29 32 16 27 3 14 34 35 12 33 18 21 17 30 9 10 29 30 30 33 22 31 5 32 15 26 6 19 20 35 7 8 14 33 29 32 18 35 20 35 17 20 26 33 26 35 31 36 11 14 20 29 32 35 32 35 29 36 33 36 33 34 31 34 10 35 28 35 25 28
output:
20
result:
ok "20"
Test #43:
score: 0
Accepted
time: 0ms
memory: 3616kb
input:
41 38 34 39 12 19 31 40 24 31 18 21 23 30 25 32 5 12 38 41 11 38 28 33 17 18 32 39 6 25 18 33 17 28 28 35 32 39 12 37 26 37 15 26 5 22 10 13 3 40 37 40 7 12 35 40 4 29 34 37 22 37 40 41 21 22 33 34 16 19 11 38 18 39 37 40 7 32
output:
20
result:
ok "20"
Test #44:
score: 0
Accepted
time: 0ms
memory: 3644kb
input:
35 36 7 20 30 35 30 33 15 22 7 32 12 27 19 28 26 29 21 34 23 26 19 24 1 4 28 33 21 30 30 31 9 32 15 20 1 18 10 27 22 27 10 33 32 35 22 33 6 25 19 32 18 21 27 34 30 33 2 23 7 28 16 21 12 31 30 35 9 12 13 26 29 32
output:
18
result:
ok "18"
Test #45:
score: 0
Accepted
time: 0ms
memory: 3860kb
input:
48 34 5 38 30 33 17 46 47 48 26 31 17 20 31 44 23 36 15 40 10 27 20 35 31 46 31 42 8 25 11 22 7 36 3 6 43 46 25 38 16 31 38 43 41 44 2 45 37 46 17 34 17 40 24 39 26 41 14 45 37 44 11 42 27 30 6 7 34 43
output:
21
result:
ok "21"
Test #46:
score: 0
Accepted
time: 0ms
memory: 3640kb
input:
35 22 21 28 10 11 12 29 26 29 22 27 5 24 26 35 4 7 13 30 17 34 24 33 26 29 22 35 20 31 13 16 5 12 20 25 33 34 25 34 7 18 8 19 4 27
output:
14
result:
ok "14"
Test #47:
score: 0
Accepted
time: 0ms
memory: 3576kb
input:
34 24 20 21 15 28 3 34 17 32 1 4 28 31 18 33 23 34 18 31 5 20 14 21 32 33 19 26 14 33 21 26 31 32 33 34 33 34 5 32 8 17 12 31 27 30 31 34 25 34
output:
15
result:
ok "15"
Test #48:
score: 0
Accepted
time: 0ms
memory: 3576kb
input:
31 12 3 26 8 23 23 28 6 11 9 20 9 22 24 29 6 13 22 27 14 17 10 17 28 31
output:
8
result:
ok "8"
Extra Test:
score: 0
Extra Test Passed