#include <stdio.h>
#include <string.h>
#include <algorithm>
#include <iostream>
#include <math.h>
#include <assert.h>
#include <vector>
#include <queue>
#include <string>
#include <map>
#include <set>

using namespace std;
typedef long long ll;
typedef unsigned int uint;
typedef unsigned long long ull;
static const double EPS = 1e-9;
static const double PI = acos(-1.0);

#define REP(i, n) for (int i = 0; i < (int)(n); i++)
#define FOR(i, s, n) for (int i = (s); i < (int)(n); i++)
#define FOREQ(i, s, n) for (int i = (s); i <= (int)(n); i++)
#define FORIT(it, c) for (__typeof((c).begin())it = (c).begin(); it != (c).end(); it++)
#define MEMSET(v, h) memset((v), h, sizeof(v))


double GaussElimination(vector<vector<double> > matrix) {
  const int n = matrix.size();
  double ret = 1.0;
  for (int x = 0; x < n; x++) {
    int pivot = x;
    for (int i = x + 1; i < n; i++) {
      if (fabs(matrix[i][x]) - fabs(matrix[pivot][x]) > EPS) {
        pivot = i;
      }
    }
    swap(matrix[x], matrix[pivot]);
    if (fabs(matrix[x][x]) < EPS) { return 0.0; }
    for (int y = 0; y < n; y++) {
      if (y == x) { continue; }
      double ratio = -matrix[y][x] /  matrix[x][x];
      matrix[y][x] = 0.0;
      for (int i = x + 1; i < n; i++) {
        matrix[y][i] += matrix[x][i] * ratio;
      }
    }
  }
  return ret;
}

typedef int Weight;
struct Edge {
  int src;
  int dest;
  Weight weight;
  Edge(int src, int dest, Weight weight) : src(src), dest(dest), weight(weight) {;}
  bool operator<(const Edge &rhs) const {
    if (weight != rhs.weight) { return weight > rhs.weight; }
    if (src != rhs.src) { return src < rhs.src; }
    return dest < rhs.dest;
  }
};
typedef vector<Edge> Edges;
typedef vector<Edges> Graph;
typedef vector<double> Array;
typedef vector<Array> Matrix;

void PrintMatrix(const Matrix &matrix) {
  for (int y = 0; y < (int)matrix.size(); y++) {
    for (int x = 0; x < (int)matrix[y].size(); x++) {
      printf("%f ", matrix[y][x]);
    }
    puts("");
  }
}

const int ITER_CNT = 10;
bool Sunny(const Graph &g) {
  const int n = g.size();
  REP(iter, ITER_CNT) {
    Matrix tutte(n, Array(n, 0));
    REP(from, n) {
      FORIT(it, g[from]) {
        int to = it->dest;
        if (to <= from) { continue; }
        if (from != 0) {
          double r = (double)(rand() + 1) / RAND_MAX * 10;
          tutte[from][to] = r;
          tutte[to][from] = -r;
        } else {
          double r1 = (double)(rand() + 1) / RAND_MAX * 10;
          double r2 = (double)(rand() + 1) / RAND_MAX * 10;
          tutte[from][to] = r1;
          tutte[to][from] = -r2;
        }
      }
    }
    if (GaussElimination(tutte) != 0.0) { return true; }
  }
  return false;
}

int n, m;
int main() {
  while (scanf("%d %d", &n, &m) > 0) {
    Graph g(n);
    REP(i, m) {
      int f, t;
      scanf("%d %d", &f, &t);
      f--; t--;
      g[f].push_back(Edge(f, t, 0));
      g[t].push_back(Edge(t, f, 0));
    }
    if (Sunny(g)) {
      puts("Yes");
    } else {
      puts("No");
    }
  }
}