Problem: The Trinitarian kingdom has exactly n = 3k cities. All of them are located on the shores of river Trissisipi, which flows through the whole kingdom. Some of the cities are located on one side of the river, and all the rest are on the other side.

Some cities are connected by bridges built between them. Each bridge connects two cities that are located on the opposite sides of the river. Between any two cities exists no more than one bridge.

The recently inaugurated King Tristan the Third is busy distributing his deputies among cities. In total there are k deputies and the king wants to commission each of them to control exactly three cities. However, no deputy can be entrusted to manage the cities, which are connected by a bridge — the deputy can set a too high fee for travelling over the bridge to benefit his pocket, which is bad for the reputation of the king.

Help King Tristan the Third distribute the deputies between the cities, if it is possible.

Input

The first line contains two integers n and m — the number of cities and bridges (3 ≤ n < 105, n = 3k, 0 ≤ m ≤ 105). Next m lines describe the bridges. The i-th line contains two integers ai and bi — the numbers of cities that are connected by the i-th bridge (1 ≤ ai, bi ≤ n, ai ≠ bi, 1 ≤ i ≤ m).

It is guaranteed that no bridge connects a city with itself and that any two cities are connected with no more than one bridge.

Output

If distributing the deputies in the required manner is impossible, print in a single line "NO" (without the quotes).

Otherwise, in the first line print "YES" (without the quotes), and in the second line print which deputy should be put in charge of each city. The i-th number should represent the number of the deputy (from 1 to k), who should be in charge of city numbered i-th in the input — overall there should be n numbers.

If there are multiple solutions, print any of them.

Examples

Input

6 6
1 2
4 1
3 5
6 5
2 6
4 6


Output

YES
1 2 1 2 2 1 

Input

3 1
1 2


Output

NO

Solution (in CPP):

Solution:
#include <bits/stdc++.h>
using namespace std;
const int INF = 1000 * 1000 * 1000 + 7;
const double EPS = 1e-9;
int bit_count(int first) {
  return first == 0 ? 0 : 1 + bit_count(first & (first - 1));
}
inline int low_bit(int first) { return first & -first; }
inline int sign(double first) {
  return first < -EPS ? -1 : first > EPS ? 1 : 0;
}
inline int sign(int first) { return (first > 0) - (first < 0); }
inline int getInt() {
  int a;
  return scanf("%d", &a) ? a : (fprintf(stderr, "trying to read\n"), -1);
}
inline double getDouble() {
  double a;
  return scanf("%lf", &a) ? a : (fprintf(stderr, "trying to read\n"), -1.0);
}
inline double myRand() {
  return ((double)rand() / RAND_MAX) + ((double)rand() / RAND_MAX / RAND_MAX);
}
void colour(int i, int col, vector<vector<int> > &a, vector<int> &c) {
  c[i] = col;
  for (typeof((a[i]).begin()) j = (a[i]).begin(); j != (a[i]).end(); ++j)
    if (c[*j] == -1) colour(*j, 1 - col, a, c);
}
void myCode() {
  int n = getInt(), m = getInt();
  vector<vector<int> > a(n, vector<int>());
  for (int i = (int)0; i < (int)m; ++i) {
    int first = getInt() - 1, second = getInt() - 1;
    a[first].push_back(second);
    a[second].push_back(first);
  }
  vector<int> c(n, -1);
  for (int i = (int)0; i < (int)n; ++i)
    if (c[i] == -1) colour(i, 0, a, c);
  int n0 = 0;
  for (int i = (int)0; i < (int)n; ++i)
    if (c[i] == 0) ++n0;
  if (n0 % 3 == 2) {
    for (int i = (int)0; i < (int)n; ++i) c[i] = 1 - c[i];
    n0 = n - n0;
  }
  bool done = false;
  if (n0 % 3 == 1) {
    vector<int> good0s, good1s;
    for (int i = (int)0; i < (int)n; ++i)
      if (c[i] == 0 && ((int)(a[i]).size()) <= n - n0 - 2) good0s.push_back(i);
    for (int i = (int)0; i < (int)n; ++i)
      if (c[i] == 1 && ((int)(a[i]).size()) <= n0 - 2) good1s.push_back(i);
    if (!done && !good0s.empty()) {
      int goodie = good0s.front();
      set<int> nearGoodie;
      for (typeof((a[goodie]).begin()) i = (a[goodie]).begin();
           i != (a[goodie]).end(); ++i)
        nearGoodie.insert(*i);
      vector<int> keyGroup;
      for (int i = (int)0; i < (int)n; ++i)
        if (c[i] == 1 && ((int)(keyGroup).size()) < 2 && !nearGoodie.count(i))
          keyGroup.push_back(i);
      int counter = 6;
      vector<int> ret(n, -1);
      ret[goodie] = ret[keyGroup[0]] = ret[keyGroup[1]] = 1;
      c[goodie] = c[keyGroup[0]] = c[keyGroup[1]] = -1;
      for (int i = (int)0; i < (int)n; ++i)
        if (c[i] == 0) ret[i] = (counter++) / 3;
      for (int i = (int)0; i < (int)n; ++i)
        if (c[i] == 1) ret[i] = (counter++) / 3;
      printf("YES\n");
      for (int i = (int)0; i < (int)n; ++i)
        printf("%d%c", ret[i], i == n - 1 ? '\n' : ' ');
      done = true;
    }
    if (!done && good1s.size() >= 2) {
      set<int> near1, near2;
      for (typeof((a[good1s[0]]).begin()) i = (a[good1s[0]]).begin();
           i != (a[good1s[0]]).end(); ++i)
        near1.insert(*i);
      for (typeof((a[good1s[1]]).begin()) i = (a[good1s[1]]).begin();
           i != (a[good1s[1]]).end(); ++i)
        near2.insert(*i);
      vector<int> key1, key2;
      for (int i = (int)0; i < (int)n; ++i)
        if (c[i] == 0 && ((int)(key1).size()) < 2 && !near1.count(i))
          key1.push_back(i);
      for (int i = (int)0; i < (int)n; ++i)
        if (c[i] == 0 && ((int)(key2).size()) < 2 && !near2.count(i))
          key2.push_back(i);
      int counter = 9;
      vector<int> ret(n, -1);
      ret[good1s[0]] = ret[key1[0]] = ret[key1[1]] = 1;
      ret[good1s[1]] = ret[key2[0]] = ret[key2[1]] = 2;
      c[good1s[0]] = c[key1[0]] = c[key1[1]] = -1;
      c[good1s[1]] = c[key2[0]] = c[key2[1]] = -1;
      for (int i = (int)0; i < (int)n; ++i)
        if (c[i] == 0) ret[i] = (counter++) / 3;
      for (int i = (int)0; i < (int)n; ++i)
        if (c[i] == 1) ret[i] = (counter++) / 3;
      printf("YES\n");
      for (int i = (int)0; i < (int)n; ++i)
        printf("%d%c", ret[i], i == n - 1 ? '\n' : ' ');
      done = true;
    }
  } else if (!done) {
    int counter = 3;
    vector<int> ret(n, -1);
    for (int i = (int)0; i < (int)n; ++i)
      if (c[i] == 0) ret[i] = (counter++) / 3;
    for (int i = (int)0; i < (int)n; ++i)
      if (c[i] == 1) ret[i] = (counter++) / 3;
    printf("YES\n");
    for (int i = (int)0; i < (int)n; ++i)
      printf("%d%c", ret[i], i == n - 1 ? '\n' : ' ');
    done = true;
  }
  if (!done) printf("NO\n");
}
int main() {
  srand(time(NULL));
  myCode();
  return 0;
}