結果

問題 No.88 次はどっちだ
ユーザー
提出日時 2024-05-14 15:16:56
言語 Rust
(1.83.0 + proconio)
結果
AC  
実行時間 1 ms / 5,000 ms
コード長 314 bytes
コンパイル時間 12,470 ms
コンパイル使用メモリ 400,620 KB
実行使用メモリ 6,824 KB
最終ジャッジ日時 2024-12-20 09:58:47
合計ジャッジ時間 13,499 ms
ジャッジサーバーID
(参考情報)
judge5 / judge4
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 11
権限があれば一括ダウンロードができます

ソースコード

diff #

use std::io::{stdin, Read};

fn main() {
	let mut s = String::new();
	stdin().read_to_string(&mut s).ok();
	let mut s = s.lines();
	let p = s.next().unwrap();
	println!(
		"{}",
		if s.flat_map(str::chars).filter(|&c| c != '.').count() % 2 == 0 {
			p.to_owned()
		} else {
			"odayukiko".replace(p, "")
		}
	);
}
0