結果

問題 No.8045 怪文書
ユーザー leaf_1415
提出日時 2019-04-01 21:29:55
言語 C++11(廃止可能性あり)
(gcc 13.3.0)
結果
TLE  
実行時間 -
コード長 227 bytes
コンパイル時間 360 ms
コンパイル使用メモリ 54,740 KB
実行使用メモリ 13,640 KB
最終ジャッジ日時 2024-11-26 11:14:05
合計ジャッジ時間 22,434 ms
ジャッジサーバーID
(参考情報)
judge1 / judge4
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 1
other AC * 13 TLE * 7
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <iostream>
#include <string>
#define llint long long

using namespace std;

llint n, m;

int main(void)
{
	cin >> n >> m;
	llint ans = 1;
	for(int i = 1; i <= n; i++) (ans *= i) %= m;
	cout << ans << endl;
	return 0;
}
0