結果

問題 No.1157 Many Quotients easy
ユーザー Konton7
提出日時 2020-08-13 19:38:07
言語 Rust
(1.83.0 + proconio)
結果
AC  
実行時間 2 ms / 2,000 ms
コード長 387 bytes
コンパイル時間 12,411 ms
コンパイル使用メモリ 379,044 KB
実行使用メモリ 5,248 KB
最終ジャッジ日時 2024-10-09 19:29:22
合計ジャッジ時間 13,449 ms
ジャッジサーバーID
(参考情報)
judge3 / judge4
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 2
other AC * 22
権限があれば一括ダウンロードができます

ソースコード

diff #

use std::io::Read;
use std::collections::BTreeSet;

fn main() {

    let mut buf = String::new();
    std::io::stdin().read_to_string(&mut buf).unwrap();
    let mut iter = buf.split_whitespace();
    
    let n: i32 = iter.next().unwrap().parse().unwrap();
    let mut ans = BTreeSet::new();
    for k in 1..(n+1){
        ans.insert(n / k);
    }
    println!("{}", ans.len());
    

}
0