結果

問題 No.1280 Beyond C
ユーザー root__786root__786
提出日時 2020-11-06 22:11:58
言語 C++17
(gcc 13.2.0 + boost 1.83.0)
結果
WA  
実行時間 -
コード長 760 bytes
コンパイル時間 2,125 ms
コンパイル使用メモリ 206,612 KB
実行使用メモリ 10,240 KB
最終ジャッジ日時 2023-09-29 18:53:36
合計ジャッジ時間 11,835 ms
ジャッジサーバーID
(参考情報)
judge15 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 WA -
testcase_01 WA -
testcase_02 WA -
testcase_03 WA -
testcase_04 WA -
testcase_05 WA -
testcase_06 WA -
testcase_07 WA -
testcase_08 WA -
testcase_09 WA -
testcase_10 WA -
testcase_11 WA -
testcase_12 WA -
testcase_13 WA -
testcase_14 WA -
testcase_15 TLE -
testcase_16 WA -
testcase_17 WA -
testcase_18 WA -
testcase_19 WA -
testcase_20 TLE -
testcase_21 -- -
testcase_22 -- -
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <bits/stdc++.h>
#include <iostream>
using namespace std;
#define int long long int 
#define ull unsigned long long int 

signed main() {
    int n,m,c;
    cin>>n>>m>>c;
    int a[n];
    int b[m];
    set<int> aa,bb;
    for(int i=0;i<n;i++){
        cin>>a[i];
        aa.insert(a[i]);
    }
    for(int j=0;j<m;j++) 
        {
        cin>>b[j];
        bb.insert(b[j]);
    }
    vector<int> A,B;
    for(auto& i:aa){
        A.push_back(i);
    }
     for(auto& i:bb){
        B.push_back(i);
    }      
    int cc=0;
    int nn=A.size();
    for(int i=0;i<nn;i++){
        for(int j=0;j<B.size();j++){
            if(A[i]*B[j]>=c) cc++;
        }
    }
    cout<<cc<<endl;
    double gg=(1.0/cc);
    cout<<fixed<<setprecision(6)<<(gg)<<endl;
}
0