結果

問題 No.242 ビンゴゲーム
ユーザー tempura_pp
提出日時 2018-10-14 19:05:10
言語 C++11(廃止可能性あり)
(gcc 13.3.0)
結果
RE  
実行時間 -
コード長 854 bytes
コンパイル時間 710 ms
コンパイル使用メモリ 87,292 KB
実行使用メモリ 6,820 KB
最終ジャッジ日時 2024-10-12 18:20:59
合計ジャッジ時間 2,484 ms
ジャッジサーバーID
(参考情報)
judge2 / judge5
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 1 RE * 2
other AC * 1 RE * 7
権限があれば一括ダウンロードができます

ソースコード

diff #

#include<iostream>
#include<string>
#include<algorithm>
#include<vector>
#include<iomanip>
#include<math.h>
#include<complex>
#include<queue>
#include<deque>
#include<stack>
#include<map>
#include<set>
#include<bitset>
#include<functional>
using namespace std;
#define REP(i,m,n) for(int i=(int)m ; i < (int) n ; ++i )
#define rep(i,n) REP(i,0,n)
typedef long long ll;
typedef pair<int,int> pint;
typedef pair<ll,int> pli;
const int inf=1e9+7;
const ll longinf=1LL<<60 ;
const ll mod=1e9+7 ;

ll dp[6000];
ll cnt[6000];
int main(){
    int n;cin>>n;
    if(n<=4){
        cout<<0<<endl;
        return 0;
    }
    double comb[100][100];
    comb[0][0]=1.0;
    rep(i,100)rep(j,i+2){
        if(j==0)comb[i+1][j]=1.0;
        else comb[i+1][j]=comb[i][j]+comb[i][j-1];
    }
    cout<<setprecision(12)<<comb[94][n-5]/comb[99][n]*12<<endl;
    return 0;
}
0