#include <bits/stdc++.h>
using namespace std;
int n, m, tot, ans, last;
int x[100001];
char ch[100001][2];
bool a[100001], b[100001], del[100001];
int main() {
  memset(b, 1, sizeof(b));
  scanf("%d%d", &n, &m);
  for (int i = 1; i <= m; i++) {
    scanf("%s", ch[i]);
    scanf("%d", &x[i]);
  }
  for (int i = m; i > 0; i--) {
    if (ch[i][0] == '-')
      a[x[i]] = 1;
    else
      a[x[i]] = 0;
  }
  for (int i = 1; i <= n; i++)
    if (a[i]) tot++;
  for (int i = 1; i <= m; i++) {
    if (ch[i][0] == '-') {
      tot--;
      if (tot > 0) del[x[i]] = 1;
      last = x[i];
      if (i != m && !tot) b[x[i]] = 0;
    } else {
      if (tot > 0 || ((x[i] != last) && last)) del[x[i]] = 1;
      tot++;
      b[x[i]] = 1;
    }
  }
  for (int i = 1; i <= n; i++)
    if (!del[i] && b[i]) ans++;
  printf("%d\n", ans);
  for (int i = 1; i <= n; i++)
    if (!del[i] && b[i]) printf("%d ", i);
  return 0;
}
