#include <bits/stdc++.h>
using namespace std;
#pragma GCC optimize("O3")
const int mod = (1e9) + 7, mod2 = 998244353;
const long double eps = 1e-20;
const int siz = 1e6 + 5, siz2 = 1e6 + 5, lg = 20, block = 317, block2 = 1000,
          mxv = 5e5;
int n, m, le[siz];
vector<int> adj[siz];
struct edge {
  int u, v;
};
edge es[siz * 2];
int getv(int u, int e) { return es[e].u == u ? es[e].v : es[e].u; }
vector<int> eulerps;
vector<int> st;
bool evis[siz * 2], nvis[siz], del[siz * 2];
void eulerdfs(int node, int pe) {
  nvis[node] = true;
  evis[pe] = true;
  int sz = adj[node].size();
  for (; le[node] < sz; le[node]++) {
    int e = adj[node][le[node]];
    if (!evis[e]) {
      eulerdfs(getv(node, e), e);
    }
  }
  if (pe != 0) {
    eulerps.push_back(pe);
  }
}
int main() {
  scanf("%d%d", &n, &m);
  for (int i = 1; i <= m; i++) {
    int u, v;
    scanf("%d%d", &u, &v);
    es[i] = {u, v};
    adj[u].push_back(i);
    adj[v].push_back(i);
  }
  int cur = m;
  for (int i = 1; i <= n; i++) {
    if (adj[i].size() % 2) {
      es[++cur] = {0, i};
      adj[0].push_back(cur);
      adj[i].push_back(cur);
    }
  }
  for (int i = 1; i <= n; i++) {
    if (!nvis[i] && adj[i].size()) {
      st.push_back(eulerps.size());
      eulerdfs(i, 0);
    }
  }
  int stsz = st.size();
  for (int stv = 0; stv < stsz; stv++) {
    int curstv = st[stv];
    int sz = stv < stsz - 1 ? st[stv + 1] - curstv : eulerps.size() - curstv;
    for (int i = curstv + 1; i < sz; i += 2) {
      int e = eulerps[curstv + i], aft = i + 1 < curstv + sz ? i + 1 : curstv;
      if (e > m) {
        del[e] = true;
        continue;
      } else if (eulerps[i - 1] > m) {
        del[eulerps[i - 1]] = true;
      } else if (eulerps[aft] > m) {
        del[eulerps[aft]] = true;
      } else {
        del[e] = true;
      }
    }
  }
  int anssz = 0;
  for (int i = 1; i <= m; i++) {
    if (!del[i]) {
      anssz++;
    }
  }
  printf("%d\n", anssz);
  for (int i = 1; i <= m; i++) {
    if (!del[i]) {
      printf("%d %d\n", es[i].u, es[i].v);
    }
  }
  return 0;
}
