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 JAVA):

Solution:
import static java.lang.Math.*;
import static java.lang.System.currentTimeMillis;
import static java.lang.System.exit;
import static java.lang.System.arraycopy;
import static java.util.Arrays.sort;
import static java.util.Arrays.binarySearch;
import static java.util.Arrays.fill;
import java.util.*;
import java.io.*;

public class Main {

	public static void main(String[] args) throws IOException {
		try {
			if (new File("input.txt").exists())
				System.setIn(new FileInputStream("input.txt"));
		} catch (SecurityException e) {
		}
		new Thread(null, new Runnable() {
			public void run() {
				try {
					new Main().run();
				} catch (IOException e) {
					e.printStackTrace();
					exit(999);
				}
			}
		}, "kek", 1 << 23).start();
	}

	BufferedReader in;
	PrintWriter out;
	StringTokenizer st = new StringTokenizer("");

	private void run() throws IOException {
		in = new BufferedReader(new InputStreamReader(System.in));
		out = new PrintWriter(System.out);
		solve();
		in.close();
		out.close();
	}

	MultiList g = new MultiList(100000, 100000 * 2 + 1);
	int used[] = new int[100000];
	int type[] = new int[100000];
	int tick = 1;
	int n;
	int deg[] = new int[100000];
	int ans[] = new int[100000];
	Q qu = new Q();

	class Q {
		int h, t;
		int m[];

		public Q() {
			m = new int[100000];
			h = t = 0;
		}

		void push(int x) {
			m[t++] = x;
		}

		int pop() {
			return m[h++];
		}
	}

	int stack[] = new int[100000];
	int ps = 0;
	private void solve() throws IOException {
		n = nextInt();
		int m = nextInt();
		for (int i = 0; i < m; i++) {
			int a = nextInt() - 1;
			int b = nextInt() - 1;
			g.add(a, b);
			g.add(b, a);
			deg[a]++;
			deg[b]++;
		}
		fill(type, -1);
		for (int i = 0; i < n; i++) {
			if (type[i] == -1) {
				type[i] = 0;
				tick++;
				int cnt0 = 1;
				int cnt1 = 0;
				used[i] = tick;
				ps = 0;
				stack[ps++] = i;
				qu.push(i);
				while (qu.h != qu.t) {
					int v = qu.pop();
					for (int j = g.head[v]; j != 0; j = g.next[j]) {
						int nv = g.vert[j];
						if (type[nv] != -1)
							continue;
						type[nv] = 1 - type[v];
						used[nv] = tick;
						if(type[nv] == 0)
							cnt0++;
						else
							cnt1++;
						stack[ps++] = nv;
						qu.push(nv);
					}
				}
				if(cnt1 == 1){
					while(ps != 0){
						int id = stack[--ps];
						type[id] = 1 - type[id];
					}
				}
			}
		}
		int cnt1 = 0;
		int cnt2 = 0;
		for (int i = 0; i < n; i++)
			if (type[i] == 0)
				cnt1++;
			else
				cnt2++;

		boolean ok = true;
		fill(ans, -1);
		int it = 1;
		if (cnt1 % 3 != 0) {
			if (cnt1 % 3 == 2) {
				for (int i = 0; i < n; i++)
					type[i] = 1 - type[i];
				int d = cnt1;
				cnt1 = cnt2;
				cnt2 = d;
			}
			int i = 0;
			chk: for (; i < n; i++)
				if (type[i] == 0 && deg[i] <= cnt2 - 2) {
					tick++;
					for(int j = g.head[i]; j != 0; j = g.next[j]){
						int nv = g.vert[j];
						used[nv] = tick;
					}
					ans[i] = it;
					int cnt = 0;
					for(int j = 0; i < n && cnt < 2; j++){
						if(used[j] != tick && type[j] == 1){
							ans[j] = it;
							cnt++;
						}
					}
					it++;
					break chk;
				}
			if(i == n) ok = false;
		}
		if(!ok){
			boolean kek = true;
			while(cnt2 % 3 != 0 && kek){
				kek = false;
				int i = 0;
				chk: for (; i < n; i++)
					if (type[i] == 1 && deg[i] <= cnt1 - 2 && ans[i] == -1) {
						tick++;
						for(int j = g.head[i]; j != 0; j = g.next[j]){
							int nv = g.vert[j];
							used[nv] = tick;
						}
						ans[i] = it;
						int cnt = 0;
						for(int j = 0; j < n && cnt < 2; j++){
							if(used[j] != tick && type[j] == 0 && ans[j] == -1){
								for(int k = g.head[j]; k != 0; k = g.next[k])
									deg[g.vert[k]]--;
								ans[j] = it;
								cnt++;
							}
						}
						cnt2--;
						cnt1 -= 2;
						it++;
						break chk;
					}
				if(i != n)
					kek = true;
			}
			if(cnt2 % 3 == 0) ok = true;
		}
		
		int cnt = 0;
		for(int i = 0; i < n; i++){
			if(type[i] == 0 && ans[i] == -1){
				cnt++;
				ans[i] = it;
				if(cnt == 3){
					cnt = 0;
					it++;
				}
			}
		}
		
		for(int i = 0; i < n; i++){
			if(type[i] == 1 && ans[i] == -1){
				cnt++;
				ans[i] = it;
				if(cnt == 3){
					cnt = 0;
					it++;
				}
			}
		}
		
		if(ok){
			out.println("YES");
			for(int i = 0; i < n; i++){
				if(i != 0)
					out.print(" ");
				out.print(ans[i]);
			}
			out.println();
		} else {
			out.println("NO");
		}
//		System.err.println(Arrays.toString(type));
	}

	class MultiList {
		int[] head, vert, next;
		int cnt;

		public MultiList(int h, int s) {
			s++;
			cnt = 1;
			head = new int[h];
			vert = new int[s];
			next = new int[s];
		}

		void add(int h, int v) {
			vert[cnt] = v;
			next[cnt] = head[h];
			head[h] = cnt++;
		}
	}

	String nextToken() throws IOException {
		while (!st.hasMoreTokens())
			st = new StringTokenizer(in.readLine());
		return st.nextToken();
	}

	int nextInt() throws IOException {
		return Integer.parseInt(nextToken());
	}

	long nextLong() throws IOException {
		return Long.parseLong(nextToken());
	}

	double nextDouble() throws IOException {
		return Double.parseDouble(nextToken());
	}

	String nextLine() throws IOException {
		st = new StringTokenizer("");
		return in.readLine();
	}

	boolean EOF() throws IOException {
		while (!st.hasMoreTokens()) {
			String s = in.readLine();
			if (s == null)
				return true;
			st = new StringTokenizer(s);
		}
		return false;
	}
}