結果
| 問題 | No.365 ジェンガソート |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2019-04-24 05:24:28 |
| 言語 | Rust (1.94.0 + proconio + num + itertools) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 444 bytes |
| 記録 | |
| コンパイル時間 | 2,536 ms |
| コンパイル使用メモリ | 188,100 KB |
| 実行使用メモリ | 6,400 KB |
| 最終ジャッジ日時 | 2026-05-07 05:32:47 |
| 合計ジャッジ時間 | 4,072 ms |
|
ジャッジサーバーID (参考情報) |
judge1_0 / judge3_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 18 WA * 23 |
ソースコード
use std::io::{self, BufRead};
fn get_lines() -> Vec<String> {
let stdin = io::stdin();
let lines: Vec<String> = stdin.lock().lines().map(|l| l.unwrap()).collect();
return lines;
}
fn main(){
let s = &get_lines();
let mut c = 1;
for x in s[1].split(' ').map(|x| x.parse::<i32>().unwrap()) {
if x != c {
println!("{}", x - 1);
return;
}
c += 1;
}
println!("0");
}