結果

問題 No.80 四角形を描こう
ユーザー kyotoku1483
提出日時 2025-03-28 17:18:28
言語 Rust
(1.83.0 + proconio)
結果
AC  
実行時間 2 ms / 5,000 ms
コード長 326 bytes
コンパイル時間 15,351 ms
コンパイル使用メモリ 385,392 KB
実行使用メモリ 7,324 KB
最終ジャッジ日時 2025-03-28 17:18:44
合計ジャッジ時間 14,178 ms
ジャッジサーバーID
(参考情報)
judge2 / judge5
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 4
other AC * 8
権限があれば一括ダウンロードができます

ソースコード

diff #

#[allow(unused)]
use proconio::{input, marker::Chars};

fn main() {
    input! {
        d: usize,
    }
    if d < 4 {
        println!("0")
    } else {
        let mut ans = 0;
        for i in 1..=d / 2 {
            let j = (d - i * 2) / 2;
            ans = ans.max(i * j);
        }
        println!("{}", ans)
    }
}
0