結果

問題 No.211 素数サイコロと合成数サイコロ (1)
ユーザー 775_koari
提出日時 2019-11-29 21:32:44
言語 C++14
(gcc 13.3.0 + boost 1.87.0)
結果
WA  
実行時間 -
コード長 453 bytes
コンパイル時間 1,655 ms
コンパイル使用メモリ 167,140 KB
実行使用メモリ 6,820 KB
最終ジャッジ日時 2024-11-20 21:38:26
合計ジャッジ時間 2,954 ms
ジャッジサーバーID
(参考情報)
judge5 / judge2
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 25 WA * 8
権限があれば一括ダウンロードができます

ソースコード

diff #

#include<bits/stdc++.h>
#define rep(i,n) for(int (i)=0;(i)<(n);(i)++)
#define repi(i,a,b) for(int (i)=(a);(i)<(b);(i)++)
typedef long long ll;
using namespace std;

int main(){
  ios::sync_with_stdio(0);
  cin.tie(0);
  
  int k;
  cin >> k;
  int s[6] = {2,3,5,7,11,13};
  int g[6] = {4,6,8,9,10,12};
  double ans=0.0;
  rep(i,6){
    rep(j,6){
      if(s[i]*g[j]==k){
        ans++;
      }
    }
  }
  cout << (pow(ans,2.0))/36 << endl;
  return 0;
}
0