結果
| 問題 | 
                            No.88 次はどっちだ
                             | 
                    
| コンテスト | |
| ユーザー | 
                             ixTL255
                         | 
                    
| 提出日時 | 2023-01-06 23:37:46 | 
| 言語 | Rust  (1.83.0 + proconio)  | 
                    
| 結果 | 
                             
                                AC
                                 
                             
                            
                         | 
                    
| 実行時間 | 1 ms / 5,000 ms | 
| コード長 | 383 bytes | 
| コンパイル時間 | 12,262 ms | 
| コンパイル使用メモリ | 386,444 KB | 
| 実行使用メモリ | 6,820 KB | 
| 最終ジャッジ日時 | 2024-11-30 20:35:54 | 
| 合計ジャッジ時間 | 13,205 ms | 
| 
                            ジャッジサーバーID (参考情報)  | 
                        judge3 / judge4 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| other | AC * 11 | 
コンパイルメッセージ
warning: variable does not need to be mutable --> src/main.rs:8:6 | 8 | let mut cnt = itr.flat_map(|e| e.chars()).filter(|&c| c != '.').count(); | ----^^^ | | | help: remove this `mut` | = note: `#[warn(unused_mut)]` on by default
ソースコード
use std::io::Read;
fn main() {
	let mut s = String::new();
	std::io::stdin().read_to_string(&mut s).ok();
	let mut itr = s.trim().split_whitespace();
	let s = itr.next().unwrap();
	let mut cnt = itr.flat_map(|e| e.chars()).filter(|&c| c != '.').count();
	match (s, cnt % 2) {
		("oda", 0) => println!("oda"),
		("yukiko", 1) => println!("oda"),
		(_, _) => println!("yukiko"),
	};
}
            
            
            
        
            
ixTL255