結果
| 問題 | No.8045 怪文書 |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2019-04-01 23:37:42 |
| 言語 | C++11(廃止可能性あり) (gcc 13.3.0 + boost 1.89.0) |
| 結果 |
TLE
|
| 実行時間 | - |
| コード長 | 356 bytes |
| 記録 | |
| コンパイル時間 | 1,151 ms |
| コンパイル使用メモリ | 71,712 KB |
| 実行使用メモリ | 13,640 KB |
| 最終ジャッジ日時 | 2024-11-27 04:55:13 |
| 合計ジャッジ時間 | 22,797 ms |
|
ジャッジサーバーID (参考情報) |
judge1 / judge4 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 1 |
| other | AC * 13 TLE * 7 |
ソースコード
#include <cstdio>
#include <cstdlib>
#include <cstddef>
#include <vector>
#include <algorithm>
#include <cmath>
#include <string>
#include <iostream>
#include <iomanip>
int main(void)
{
long n, m;
std::cin >> n >> m;
long ret = 1;
for(long i = 1; i <= n; i++){
ret = (ret * i) % m;
}
std::cout << ret << std::endl;
return 0;
}