結果

問題 No.3019 YNeos
ユーザー ArcAki
提出日時 2025-02-14 21:39:29
言語 Rust
(1.83.0 + proconio)
結果
AC  
実行時間 1 ms / 1,000 ms
コード長 805 bytes
コンパイル時間 14,482 ms
コンパイル使用メモリ 401,964 KB
実行使用メモリ 6,820 KB
最終ジャッジ日時 2025-02-16 17:29:35
合計ジャッジ時間 15,491 ms
ジャッジサーバーID
(参考情報)
judge2 / judge5
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 41
権限があれば一括ダウンロードができます

ソースコード

diff #

#[allow(unused_imports)]
use std::{
    collections::{HashMap, HashSet, BinaryHeap, VecDeque, BTreeSet, BTreeMap},
    io::{read_to_string, stdin, Write, stdout},
};

use proconio::{input, fastout, marker::Chars};

#[fastout]
fn main(){
    input!{
		x: Chars,
		y: Chars,
	}
    if x.len()==y.len(){
        let mut res = Vec::new();
        for i in 0..x.len(){
            res.push(x[i].to_string());
            res.push(y[i].to_string());
        }
        println!("{}", res.join(""));
    } else if x.len()==y.len()+1{
        let mut res = Vec::new();
        for i in 0..y.len(){
            res.push(x[i].to_string());
            res.push(y[i].to_string());
        }
        res.push(x[x.len()-1].to_string());
        println!("{}", res.join(""));
    } else {
        println!("?");
    }
}
0