結果
| 問題 | No.72 そろばん Med | 
| コンテスト | |
| ユーザー |  RCCW | 
| 提出日時 | 2017-02-18 14:33:04 | 
| 言語 | C++11(廃止可能性あり) (gcc 13.3.0) | 
| 結果 | 
                                TLE
                                 
                             | 
| 実行時間 | - | 
| コード長 | 262 bytes | 
| コンパイル時間 | 414 ms | 
| コンパイル使用メモリ | 55,780 KB | 
| 実行使用メモリ | 16,844 KB | 
| 最終ジャッジ日時 | 2024-12-30 04:02:53 | 
| 合計ジャッジ時間 | 145,669 ms | 
| ジャッジサーバーID (参考情報) | judge4 / judge1 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| sample | AC * 2 WA * 1 | 
| other | WA * 1 TLE * 23 | 
ソースコード
#include <iostream>
#include <cstdio>
using namespace std;
#define rep(i,n) for(int i=0;i<(n);i++)
int main(){
	long long n=0;
	cin>>n;
long long u=0;
long long ans=0;
for (int i = 0; i <= n; ++i) {
ans=max(ans,i*(n-i+1)+n-i);
}
cout<<ans<<endl;
	return 0;
}
            
            
            
        