#include <bits/stdc++.h>
using namespace std;
int n, m;
int mcnt;
int cnt[100007];
int met[100007];
int lead[100007];
vector<int> metp;
vector<int> metm;
vector<int> endd;
int main() {
  scanf("%d %d", &n, &m);
  char c[1];
  int d;
  for (int i = 0; i < m; i++) {
    scanf("%s %d", &c, &d);
    if (c[0] == '-')
      met[i] = (-1) * d;
    else
      met[i] = d;
  }
  for (int i = 0; i < m; i++) {
    if (met[i] < 0)
      if (cnt[abs(met[i])] == 0) {
        metp.push_back(abs(met[i]));
        cnt[abs(met[i])] = 1;
      }
    cnt[abs(met[i])]++;
  }
  for (int i = 1; i <= n; i++) cnt[i] = 0;
  for (int i = m - 1; i >= 0; i--) {
    if (met[i] > 0)
      if (cnt[abs(met[i])] == 0) {
        metm.push_back((-1) * met[i]);
        cnt[abs(met[i])] = 1;
      }
    cnt[abs(met[i])]++;
  }
  for (int i = metp.size() - 1; i >= 0; i--) endd.push_back(metp[i]);
  for (int i = 0; i < m; i++) endd.push_back(met[i]);
  for (int i = 0; i < metm.size(); i++) endd.push_back(metm[i]);
  m = endd.size();
  for (int i = 0; i < m; i++) lead[abs(endd[i])] = 1;
  mcnt = 0;
  int pr = endd[0];
  bool f = 0;
  if (endd[m - 1] == -pr)
    for (int i = 0; i < m; i++) {
      if (endd[i] == -pr)
        if (i != m - 1)
          if (endd[i + 1] != pr || mcnt != 1) f = 1;
      if (endd[i] < 0)
        mcnt--;
      else
        mcnt++;
    }
  else
    f = 1;
  if (f == 0) lead[pr] = 0;
  mcnt = 0;
  for (int i = 1; i <= n; i++)
    if (lead[i] == 0) mcnt++;
  printf("%d\n", mcnt);
  for (int i = 1; i <= n; i++)
    if (lead[i] == 0) printf("%d ", i);
  return 0;
}
