#include <bits/stdc++.h>
const int maxn = 1e5 + 100;
const double eps = 1e-7;
const int INF = 1e9;
using namespace std;
bool f[maxn];
int a[maxn];
struct Node {
  int i, num;
  bool operator<(const Node &rhs) const {
    return i < rhs.i || (i == rhs.i && num < rhs.num);
  }
};
int main() {
  int n, m;
  scanf("%d%d", &n, &m);
  for (int i = 1; i <= n; i++) {
    f[i] = true;
    a[i] = i;
  }
  set<Node> S1, S2;
  set<Node>::iterator it, it1;
  int cnt = n;
  char key[10];
  int id;
  for (int i = 1; i <= m; i++) {
    scanf("%s %d", key, &id);
    if (key[0] == '+') {
      int d = S2.erase((Node){a[id], id});
      if (S2.size() && d == 0) f[id] = false;
      if (S1.size()) f[id] = false;
      a[id] = ++cnt;
      S1.insert((Node){a[id], id});
      for (it = S2.begin(); it != S2.end(); it++) {
        f[it->num] = false;
      }
      S2.clear();
    } else {
      it1 = it = S1.upper_bound((Node){a[id], id});
      if (it != S1.end()) {
        f[id] = false;
        f[it->num] = false;
      }
      S1.erase((Node){a[id], id});
      for (it = S2.begin(); it != S2.end(); it++) {
        f[it->num] = false;
      }
      S2.clear();
      S2.insert((Node){a[id], id});
    }
  }
  int num = 0;
  for (int i = 1; i <= n; i++)
    if (f[i]) num++;
  cout << num << endl;
  for (int i = 1; i <= n; i++)
    if (f[i]) cout << i << " ";
  cout << endl;
}
