Submission #20527688


Source Code Expand

use proconio::{fastout, input};

#[fastout]
fn main() {
    input! {in_n: usize};
    let mut price = -1;

    for _ in 0..in_n {
        input! {in_a: i32, in_p: i32, in_x: i32};

        if in_a >= in_x {
            continue;
        }

        if price == -1 || price > in_p {
            price = in_p;
        }
    }

    println!("{}", price);
}

Submission Info

Submission Time
Task B - Play Snuke
User takedarts
Language Rust (1.42.0)
Score 200
Code Size 353 Byte
Status AC
Exec Time 29 ms
Memory 5412 KiB

Judge Result

Set Name Sample All
Score / Max Score 0 / 0 200 / 200
Status
AC × 3
AC × 18
Set Name Test Cases
Sample 01_sample.txt, 02_sample.txt, 03_sample.txt
All 01_sample.txt, 02_sample.txt, 03_sample.txt, 04_small.txt, 05_small.txt, 06_small.txt, 07_small.txt, 08_small.txt, 09_large.txt, 10_large.txt, 11_large.txt, 12_large.txt, 13_large.txt, 14_ng.txt, 15_ng.txt, 16_max.txt, 17_max.txt, 18_max.txt
Case Name Status Exec Time Memory
01_sample.txt AC 6 ms 1920 KiB
02_sample.txt AC 1 ms 1916 KiB
03_sample.txt AC 1 ms 2112 KiB
04_small.txt AC 1 ms 2048 KiB
05_small.txt AC 2 ms 2128 KiB
06_small.txt AC 1 ms 2136 KiB
07_small.txt AC 1 ms 2132 KiB
08_small.txt AC 1 ms 2136 KiB
09_large.txt AC 14 ms 2956 KiB
10_large.txt AC 16 ms 3640 KiB
11_large.txt AC 16 ms 3592 KiB
12_large.txt AC 15 ms 3444 KiB
13_large.txt AC 11 ms 2692 KiB
14_ng.txt AC 3 ms 2172 KiB
15_ng.txt AC 12 ms 3264 KiB
16_max.txt AC 29 ms 5140 KiB
17_max.txt AC 28 ms 4980 KiB
18_max.txt AC 29 ms 5412 KiB