結果
問題 | No.1603 Manhattan Social Distance |
ユーザー |
![]() |
提出日時 | 2021-07-16 21:36:12 |
言語 | Java (openjdk 23) |
結果 |
AC
|
実行時間 | 48 ms / 2,000 ms |
コード長 | 457 bytes |
コンパイル時間 | 2,598 ms |
コンパイル使用メモリ | 74,444 KB |
実行使用メモリ | 50,268 KB |
最終ジャッジ日時 | 2024-07-06 08:33:45 |
合計ジャッジ時間 | 3,180 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 16 |
ソースコード
import java.io.*; import java.util.*; class Main { public static void main(String args[])throws Exception { BufferedReader bu=new BufferedReader(new InputStreamReader(System.in)); StringBuilder sb=new StringBuilder(); String s[]=bu.readLine().split(" "); int n=Integer.parseInt(s[0]),h=Integer.parseInt(s[1]),w=Integer.parseInt(s[2]); long ans=1l*(n/2)*(n-n/2)*(h+w-2); System.out.print(ans); } }