結果

問題 No.400 鏡
ユーザー cra77756176
提出日時 2022-12-01 21:25:00
言語 Rust
(1.83.0 + proconio)
結果
AC  
実行時間 1 ms / 2,000 ms
コード長 351 bytes
コンパイル時間 21,320 ms
コンパイル使用メモリ 400,628 KB
実行使用メモリ 5,248 KB
最終ジャッジ日時 2024-10-09 02:07:06
合計ジャッジ時間 22,419 ms
ジャッジサーバーID
(参考情報)
judge5 / judge2
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 4
other AC * 8
権限があれば一括ダウンロードができます

ソースコード

diff #

use std::io;

fn main() {
    let mut s = String::new();
    io::stdin().read_line(&mut s).ok();
    let s = s.trim();

    let answer = s
        .chars()
        .rev()
        .map(|c| match c {
            '<' => '>',
            '>' => '<',
            _ => unreachable!(),
        })
        .collect::<String>();

    println!("{}", answer);
}
0