結果
問題 |
No.723 2つの数の和
|
ユーザー |
![]() |
提出日時 | 2024-02-20 13:03:18 |
言語 | C++23 (gcc 13.3.0 + boost 1.87.0) |
結果 |
RE
|
実行時間 | - |
コード長 | 294 bytes |
コンパイル時間 | 4,002 ms |
コンパイル使用メモリ | 277,896 KB |
実行使用メモリ | 440,704 KB |
最終ジャッジ日時 | 2024-09-29 03:42:30 |
合計ジャッジ時間 | 9,814 ms |
ジャッジサーバーID (参考情報) |
judge3 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 10 RE * 3 TLE * 1 -- * 8 |
ソースコード
#include<bits/stdc++.h> using namespace std; #include<atcoder/convolution> using namespace atcoder; typedef long long ll; int main(){ ll n,x;cin >> n >> x; vector<ll>cnt(x+1); for(;n--;){ ll a;cin >> a; if(a<=x)cnt[a]++; } auto ret = convolution_ll(cnt,cnt); cout << ret[x] << endl; }