結果

問題 No.500 階乗電卓
ユーザー kkslucy1
提出日時 2018-03-14 03:53:20
言語 C++11(廃止可能性あり)
(gcc 13.3.0)
結果
TLE  
実行時間 -
コード長 208 bytes
コンパイル時間 1,544 ms
コンパイル使用メモリ 157,528 KB
実行使用メモリ 16,960 KB
最終ジャッジ日時 2024-11-24 19:55:18
合計ジャッジ時間 32,274 ms
ジャッジサーバーID
(参考情報)
judge4 / judge3
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 7 WA * 4 TLE * 9
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <bits/stdc++.h>
using namespace std;
typedef long long ll;

int main() {
	ll n;
	cin >> n;
	ll ans = 1;
	while (n != 0) {
		ans *= n--;
		ans %= 1000000000000;
	}
	cout << ans << endl;


	return 0;
}
0