結果

問題 No.3347 Guess The Array
コンテスト
ユーザー rhoo
提出日時 2025-11-13 23:41:16
言語 Rust
(1.83.0 + proconio)
結果
RE  
実行時間 -
コード長 583 bytes
コンパイル時間 13,858 ms
コンパイル使用メモリ 400,284 KB
実行使用メモリ 26,240 KB
平均クエリ数 1.00
最終ジャッジ日時 2025-11-13 23:41:36
合計ジャッジ時間 18,557 ms
ジャッジサーバーID
(参考情報)
judge5 / judge4
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other WA * 1 RE * 45
権限があれば一括ダウンロードができます

ソースコード

diff #

#![allow(unused_imports,non_snake_case,dead_code)]
use std::{cmp::Reverse as Rev,ops::Range,collections::*,iter::*,mem::swap};
use proconio::{marker::*,*};


use proconio::input_interactive as input;

// #[fastout]
fn main(){
    input!{
        n:usize,
    }

    let mut a=(0..n).collect::<Vec<_>>();
    a.sort_by(|&i,&j|{
        println!("? 2 {} {}",i,j);
        input!{
            s:String,
        }
        if s=="Yes"{
            0u64.cmp(&1)
        } else{
            1u64.cmp(&0)
        }
    });

    print!("!");
    for &a in &a{
        print!(" {a}");
    }
}
0