結果
| 問題 |
No.5017 Tool-assisted Shooting
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2023-07-16 16:27:54 |
| 言語 | Rust (1.83.0 + proconio) |
| 結果 |
RE
|
| 実行時間 | - |
| コード長 | 955 bytes |
| コンパイル時間 | 688 ms |
| コンパイル使用メモリ | 142,812 KB |
| 実行使用メモリ | 24,516 KB |
| スコア | 74,830 |
| 平均クエリ数 | 399.74 |
| 最終ジャッジ日時 | 2023-07-16 16:28:12 |
| 合計ジャッジ時間 | 9,319 ms |
|
ジャッジサーバーID (参考情報) |
judge11 / judge14 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 18 RE * 82 |
ソースコード
// type Output = Vec<char>;
fn main() {
for _ in 0..1000 {
if let Some(_input) = read_input() {
println!("S");
} else {
break;
}
}
}
fn read_input() -> Option<Input> {
let mut n = String::new();
std::io::stdin().read_line(&mut n).unwrap();
if n == "-1" {
return None;
}
let n = n.trim().parse::<usize>().unwrap();
let mut es = vec![];
for _ in 0..n {
let mut line = String::new();
std::io::stdin().read_line(&mut line).unwrap();
let mut tokens = line.split_whitespace();
let h = tokens.next().unwrap().parse::<usize>().unwrap();
let p = tokens.next().unwrap().parse::<usize>().unwrap();
let x = tokens.next().unwrap().parse::<usize>().unwrap();
es.push((h, p, x));
}
Some(Input { n, es })
}
#[allow(dead_code)]
#[derive(Debug)]
struct Input {
n: usize,
es: Vec<(usize, usize, usize)>,
}