結果
問題 |
No.9000 Hello World! (テスト用)
|
ユーザー |
![]() |
提出日時 | 2020-10-22 20:26:09 |
言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
結果 |
AC
|
実行時間 | 2 ms / 5,000 ms |
コード長 | 848 bytes |
コンパイル時間 | 4,138 ms |
コンパイル使用メモリ | 250,760 KB |
最終ジャッジ日時 | 2025-01-15 12:29:26 |
ジャッジサーバーID (参考情報) |
judge5 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 4 |
ソースコード
#include<bits/stdc++.h> #include <atcoder/all> #define rep(i,n) for(int i = 0;i<n;i++) using namespace std; using namespace atcoder; typedef pair<int,int> P; typedef long long ll; template<class T> inline bool chmax(T& a, T b) { if (a < b) { a = b; return 1; } return 0;} template<class T> inline bool chmin(T& a, T b) { if (a > b) { a = b; return 1; } return 0;} using mint = modint1000000007; struct combination { vector<mint> fact,ifact; combination(int n): fact(n+1),ifact(n+1) { fact[0] = 1; for(int i = 1; i <= n;i++) fact[i] = fact[i-1]*i; ifact[n] = fact[n].inv(); for(int i = n;i>=1;i--) ifact[i-1] = ifact[i]*i; } mint operator ()(int n,int k) { if(k < 0 || k > n) return 0; return fact[n]*ifact[k]*ifact[n-k]; } }; int main() { cout << "Hello World!" << endl; }