結果

問題 No.183 たのしい排他的論理和(EASY)
ユーザー hokuto
提出日時 2021-08-30 22:13:52
言語 C++17(clang)
(17.0.6 + boost 1.87.0)
結果
TLE  
実行時間 -
コード長 643 bytes
コンパイル時間 2,204 ms
コンパイル使用メモリ 142,300 KB
実行使用メモリ 10,624 KB
最終ジャッジ日時 2024-11-24 06:30:59
合計ジャッジ時間 43,863 ms
ジャッジサーバーID
(参考情報)
judge5 / judge4
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 2
other AC * 12 TLE * 6
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <iostream>
#include <utility>
#include <vector>
#include <string>
#include <cmath>
#include <algorithm>
#include <functional>
#include <iomanip>
#include <map>
#include <set>
#include <queue>
using namespace std;
using ll = long long int;
#define chmax(x,y)  x = (x > (y)) ? x : (x = (y));
#define chmin(x,y)  x = (x < (y)) ? x : (x = (y));


int main(int argc, char const *argv[])
{
  set<ll> st;
  st.insert(0);
  int N; cin >> N;
  for(int i=0;i<N;++i)
  {
    ll a; cin >> a;
    vector<ll> A;
    for(auto &s : st)
    {
      A.push_back(s^a);
    }
    for(auto &e : A)st.insert(e);
  }
  std::cout << st.size() << std::endl;
}
0