Alice and Bob are playing a game on a line with n cells. There are n cells labeled from 1 through n. For each i from 1 to n-1, cells i and i+1 are adjacent.

Alice initially has a token on some cell on the line, and Bob tries to guess where it is. 

Bob guesses a sequence of line cell numbers x_1, x_2, …, x_k in order. In the i-th question, Bob asks Alice if her token is currently on cell x_i. That is, Alice can answer either "YES" or "NO" to each Bob's question.

At most one time in this process, before or after answering a question, Alice is allowed to move her token from her current cell to some adjacent cell. Alice acted in such a way that she was able to answer "NO" to all of Bob's questions.

Note that Alice can even move her token before answering the first question or after answering the last question. Alice can also choose to not move at all.

You are given n and Bob's questions x_1, …, x_k. You would like to count the number of scenarios that let Alice answer "NO" to all of Bob's questions. 

Let (a,b) denote a scenario where Alice starts at cell a and ends at cell b. Two scenarios (a_i, b_i) and (a_j, b_j) are different if a_i ≠ a_j or b_i ≠ b_j.

Input

The first line contains two integers n and k (1 ≤ n,k ≤ 10^5) — the number of cells and the number of questions Bob asked.

The second line contains k integers x_1, x_2, …, x_k (1 ≤ x_i ≤ n) — Bob's questions.

Output

Print a single integer, the number of scenarios that let Alice answer "NO" to all of Bob's questions.

Examples

Input


5 3
5 1 4


Output


9


Input


4 8
1 2 3 4 4 3 2 1


Output


0


Input


100000 1
42


Output


299997

Note

The notation (i,j) denotes a scenario where Alice starts at cell i and ends at cell j.

In the first example, the valid scenarios are (1, 2), (2, 1), (2, 2), (2, 3), (3, 2), (3, 3), (3, 4), (4, 3), (4, 5). For example, (3,4) is valid since Alice can start at cell 3, stay there for the first three questions, then move to cell 4 after the last question. 

(4,5) is valid since Alice can start at cell 4, stay there for the first question, the move to cell 5 for the next two questions. Note that (4,5) is only counted once, even though there are different questions that Alice can choose to do the move, but remember, we only count each pair of starting and ending positions once.

In the second example, Alice has no valid scenarios.

In the last example, all (i,j) where |i-j| ≤ 1 except for (42, 42) are valid scenarios.
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.StringTokenizer;

public class codeforces557 {

	int n,m,k,h;
	int mli[];
	int mri[];
	int mxi[];
	int a[][];
	int b[][];
	int atemp[][];
	int btemp[][];
	int kints[];
	public long q1() {
		int maxHeight[] = new int[n];
		for(int i = 0;i<n;i++) {
			maxHeight[i] = h;
		}
		for(int i = 0;i<m;i++) {
			for(int k = mli[i]-1;k<=mri[i]-1;k++) {
				if(mxi[i]< maxHeight[k])
					maxHeight[k] = mxi[i];
			}
		}
		long sum = 0;
		for(int i = 0;i<n;i++) {
			sum+=maxHeight[i]*maxHeight[i];
		}
		return sum;
	}
	
	public int q2() {
		for(int i =0;i<n;i++) {
			for(int j = 0;j<m;j++) {
				if(i == 0 & j==0)
					continue;
				if(j == 0) {
					// up only
					if(a[i][j] <= a[i-1][j] || b[i][j]<=b[i-1][j]) {
						// violation
						// swap
						int temp = a[i][j];
						a[i][j] = b[i][j];
						b[i][j] = temp;
						
						if(a[i][j] <= a[i-1][j] || b[i][j]<=b[i-1][j]) {
							// violation after swap
							return -1;
						}
					}
				}
				else if(i == 0) {
					if(a[i][j] <= a[i][j-1] || b[i][j]<=b[i][j-1]) {
						// violation
						// swap
						int temp = a[i][j];
						a[i][j] = b[i][j];
						b[i][j] = temp;
						
						if(a[i][j] <= a[i][j-1] || b[i][j]<=b[i][j-1]) {
							// violation after swap
							return -1;
						}
					}
				} else {
					// i and j not 0
					if(a[i][j]<=a[i][j-1] || a[i][j]<=a[i-1][j] || b[i][j]<=b[i-1][j] || b[i][j]<=b[i][j-1]) {
						// violation
						// swap
						int temp = a[i][j];
						a[i][j] = b[i][j];
						b[i][j] = temp;
						
						if(a[i][j]<=a[i][j-1] || a[i][j]<=a[i-1][j] || b[i][j]<=b[i-1][j] || b[i][j]<=b[i][j-1]) {
							// violation after swap
							return -1;
						}
					}
				}
				
			}
		}
	return 0;
	}
	
	public int q2rev() {
		for(int i =n-1;i>=0;i--) {
			for(int j = m-1;j>=0;j--) {
				if(i == n-1 & j==m-1)
					continue;
				if(j == m-1) {
					// down only
					if(atemp[i][j] >= atemp[i+1][j] || btemp[i][j]>=btemp[i+1][j]) {
						// violation
						// swap
						int temp = a[i][j];
						a[i][j] = b[i][j];
						b[i][j] = temp;
						
						if(atemp[i][j] >= atemp[i+1][j] || btemp[i][j]>=btemp[i+1][j]) {
							// violation after swap
							return -1;
						}
					}
				}
				else if(i == n-1) {
					// right only
					if(atemp[i][j] >= atemp[i][j+1] || btemp[i][j]>=btemp[i][j+1]) {
						// violation
						// swap
						int temp = a[i][j];
						a[i][j] = b[i][j];
						b[i][j] = temp;
						
						if(atemp[i][j] >= atemp[i][j+1] || btemp[i][j]>=btemp[i][j+1]) {
							// violation after swap
							return -1;
						}
					}
				} else {
					// i and j not 0
					if(atemp[i][j]>=atemp[i][j+1] || atemp[i][j]>=atemp[i+1][j] || btemp[i][j]>=btemp[i+1][j] || btemp[i][j]>=btemp[i][j+1]) {
						// violation
						// swap
						int temp = a[i][j];
						a[i][j] = b[i][j];
						b[i][j] = temp;
						
						if(atemp[i][j]>=atemp[i][j+1] || atemp[i][j]>=atemp[i+1][j] || btemp[i][j]>=btemp[i+1][j] || btemp[i][j]>=btemp[i][j+1]) {
							// violation after swap
							return -1;
						}
					}
				}
				
			}
		}
	return 0;
	}
	
	public int q3() {
		int ans = 0;
		int count[] = new int[n+2];
		int extra[] = new int[n+2];
		for(int i =0;i<n+2;i++) {
			count[i] = 0;
			extra[i] = 0;
		}
		for(int i = 0;i<k;i++) {
			count[kints[i]]++;
			if(count[kints[i]+1] > 0 && count[kints[i]-1] > 0) {
				extra[kints[i]] = 2;
			}
			else if(kints[i]+1 > 0) {
				extra[kints[i]] = 1;
			}
			else if(kints[i]-1 > 0) {
				extra[kints[i]] = -1;
			}
		}
		count[0] = 2;
		count[n+1] = 2;
		for(int i =1;i<=n;i++) {
			if(count[i] == 0) {
				ans++;
				if(count[i-1]<=1)
					ans++;
				if(count[i+1]<=1)
					ans++;
			} else {
				if(count[i-1]<=1) {
					if(extra[i-1] < 1)
						ans++;
				}
				if(count[i+1]<=1) {
					if(extra[i+1] == 1 || extra[i+1] == 0)
						ans++;
				}
			}
		}
		return ans;
	}
	
	public int q3sol() {
		int ans = 0;
		int count[] = new int[n+2];
		int extra[] = new int[n+2];
		int first[] = new int[n+2];
		int last[] = new int[n+2];
		for(int i =0;i<n+2;i++) {
			count[i] = 0;
			extra[i] = 0;
			first[i] = -1;
			last[i] = -1;
		}
		for(int i = 0;i<k;i++) {
			count[kints[i]]++;
		}
		count[0] = 2;
		count[n+1] = 2;
		
		for(int i = 0;i<k;i++) {
			if(first[kints[i]] == -1)
				first[kints[i]] = i;
			
			if(last[kints[i]] < i)
				last[kints[i]] = i;
		}
		last[0] = Integer.MAX_VALUE;
		last[n+1] = Integer.MAX_VALUE;
		
		for(int i =1;i<=n;i++) {
			if(first[i] == -1) {
				if(i == 1 || i == n)
					ans+=2;
				else
					ans+=3;
				continue;
			}
			if(last[i-1]<=first[i])
				ans++;
			if(last[i+1]<=first[i])
				ans++;
			
			
//			if(count[i] == 0) {
//				ans++;
//				if(last[i-1]<=first[i])
//					ans++;
//				if(last[i+1]<=first[i])
//					ans++;
////				if(count[i-1]<=1)
////					ans++;
////				if(count[i+1]<=1)
////					ans++;
//			} else {
//				if(count[i-1]<=1) {
//					if(extra[i-1] < 1)
//						ans++;
//				}
//				if(count[i+1]<=1) {
//					if(extra[i+1] == 1 || extra[i+1] == 0)
//						ans++;
//				}
//			}
		}
		return ans;
		
	}
	
	public static void main(String[] args) {
		// TODO Auto-generated method stub
		codeforces557 cf = new codeforces557();
		cf.read();
		 // System.out.println(cf.q1());
//		 int res = cf.q2();
//		 int res2 = cf.q2rev();
//		 if(res == 0 || res2 == 0)
//			 System.out.println("Possible");
//		 else
//			 System.out.println("Impossible");
		// cf.printAns();
		// cf.printSequence();
		// cf.q1();
		int res = cf.q3sol();
		System.out.println(res);
	}
	
	void read() {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		StringTokenizer tokenizer = null;
		
		int nk[] = nextIntsSpace(tokenizer, br);
		n = nk[0];
		k = nk[1];
		kints = nextIntsSpace(tokenizer, br);
		
//		int nm[] = nextIntsSpace(tokenizer, br);
//		n = nm[0];
//		m = nm[1];
//		a = new int[n][m];
//		b = new int[n][m];
//		atemp = new int[n][m];
//		btemp = new int[n][m];
//		for(int i = 0;i<n;i++) {
//			a[i] = nextIntsSpace(tokenizer, br);
//		}
//		for(int i = 0;i<n;i++) {
//			b[i] = nextIntsSpace(tokenizer, br);
//		}
//		for(int i =0;i<n;i++) {
//			for(int j = 0;j<m;j++) {
//				atemp[i][j] = a[i][j];
//				btemp[i][j] = b[i][j];
//			}
//		}
		
		
		/*
		int nmh[] = nextIntsSpace(tokenizer, br);
		n = nmh[0];
		h = nmh[1];
		m = nmh[2];
		mli = new int[m];
		mri = new int[m];
		mxi = new int[m];
		for(int i =0;i<m;i++) {
			int is[] = nextIntsSpace(tokenizer, br);
			mli[i] = is[0];
			mri[i] = is[1];
			mxi[i] = is[2];
		}
		*/
		/*
		nums = nextIntsSpace(tokenizer, br);
		String input1 = next(tokenizer, br);
		int input2 = nextInt(tokenizer, br);
		String input3 = next(tokenizer, br);
		System.out.println("Input1: " + input1 + " input2: " + input2 + " input3: " + input3);
		*/
	}
	
	public String next(StringTokenizer tokenizer, BufferedReader br) {
		try {
			while (tokenizer == null || !tokenizer.hasMoreTokens()) {
				String line = br.readLine();
				if (line == null)
					throw new IOException();
				tokenizer = new StringTokenizer(line);
			}
		}
		catch(IOException e) {
			
		}
		return tokenizer.nextToken();
	}
	
	public String[] nextSpace(StringTokenizer tokenizer, BufferedReader br) {
		try {
			while (tokenizer == null || !tokenizer.hasMoreTokens()) {
				String line = br.readLine();
				if (line == null)
					throw new IOException();
				tokenizer = new StringTokenizer(line);
			}
		}
		catch(IOException e) {
			
		}
		String s[] = new String[tokenizer.countTokens()];
		int sCount = 0;
		while(tokenizer.hasMoreTokens()) {
			s[sCount++] = tokenizer.nextToken();
		}
		return s;
	}
	
	public int[] nextIntsSpace(StringTokenizer tokenizer, BufferedReader br) {
		try {
			String s[] = nextSpace(tokenizer, br);
			int n[] = new int[s.length];
			for(int i = 0;i < s.length; i++) {
				n[i] = Integer.parseInt(s[i]);
			}
			return n;
		}
		catch(Exception e) {
			e.printStackTrace();
			return new int[0];
		}
	}

	public int nextInt(StringTokenizer tokenizer, BufferedReader br) {
		try {
			
			return Integer.parseInt(next(tokenizer, br));
		}
		catch(Exception e) {
			return -1;
		}
	}

}
