結果

問題 No.1692 Expectations
ユーザー asaringoasaringo
提出日時 2021-10-01 21:29:59
言語 C++14
(gcc 12.3.0 + boost 1.83.0)
結果
AC  
実行時間 134 ms / 2,000 ms
コード長 432 bytes
コンパイル時間 1,713 ms
コンパイル使用メモリ 170,420 KB
実行使用メモリ 12,800 KB
最終ジャッジ日時 2024-07-19 10:34:29
合計ジャッジ時間 3,060 ms
ジャッジサーバーID
(参考情報)
judge4 / judge5
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 2 ms
5,248 KB
testcase_01 AC 2 ms
5,248 KB
testcase_02 AC 2 ms
5,376 KB
testcase_03 AC 2 ms
5,376 KB
testcase_04 AC 2 ms
5,376 KB
testcase_05 AC 2 ms
5,376 KB
testcase_06 AC 2 ms
5,376 KB
testcase_07 AC 2 ms
5,376 KB
testcase_08 AC 2 ms
5,376 KB
testcase_09 AC 2 ms
5,376 KB
testcase_10 AC 55 ms
5,376 KB
testcase_11 AC 53 ms
5,376 KB
testcase_12 AC 2 ms
5,376 KB
testcase_13 AC 2 ms
5,376 KB
testcase_14 AC 10 ms
5,376 KB
testcase_15 AC 111 ms
8,704 KB
testcase_16 AC 10 ms
5,376 KB
testcase_17 AC 50 ms
6,528 KB
testcase_18 AC 20 ms
5,376 KB
testcase_19 AC 134 ms
9,344 KB
testcase_20 AC 97 ms
11,392 KB
testcase_21 AC 116 ms
12,800 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

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

int n , m ;
int A[202020] ;
set<int> st ;

int main(){
    cin >> n >> m ;
    rep(i,n){
        ll a ;
        cin >> a ;
        st.insert(a) ;
    }
    cout << st.size() << " " ;
    if(st.size() == 1 && n == m) cout << 1 << endl ;
    else cout << 0 << endl ;
}
0