This is an interactive problem.

We hid from you a permutation p of length n, consisting of the elements from 1 to n. You want to guess it. To do that, you can give us 2 different indices i and j, and we will reply with p_{i} mod p_{j} (remainder of division p_{i} by p_{j}).

We have enough patience to answer at most 2 ⋅ n queries, so you should fit in this constraint. Can you do it?

As a reminder, a permutation of length n is an array consisting of n distinct integers from 1 to n in arbitrary order. For example, [2,3,1,5,4] is a permutation, but [1,2,2] is not a permutation (2 appears twice in the array) and [1,3,4] is also not a permutation (n=3 but there is 4 in the array).

Input

The only line of the input contains a single integer n (1 ≤ n ≤ 10^4) — length of the permutation.

Interaction

The interaction starts with reading n. 

Then you are allowed to make at most 2 ⋅ n queries in the following way: 

  * "? x y" (1 ≤ x, y ≤ n, x ≠ y). 



After each one, you should read an integer k, that equals p_x mod p_y. 

When you have guessed the permutation, print a single line "! " (without quotes), followed by array p and quit.

After printing a query do not forget to output end of line and flush the output. Otherwise, you will get Idleness limit exceeded. To do this, use:

  * fflush(stdout) or cout.flush() in C++;
  * System.out.flush() in Java;
  * flush(output) in Pascal;
  * stdout.flush() in Python;
  * see documentation for other languages.



Exit immediately after receiving "-1" and you will see Wrong answer verdict. Otherwise you can get an arbitrary verdict because your solution will continue to read from a closed stream.

Hack format

In the first line output n (1 ≤ n ≤ 10^4). In the second line print the permutation of n integers p_1, p_2, …, p_n.

Example

Input


3

1

2

1

0

Output


? 1 2

? 3 2

? 1 3

? 2 1

! 1 3 2
import java.io.*;
import java.util.*;

public class R669C {
	public static void main(String[] args) {
		JS scan = new JS();
		int n = scan.nextInt();
		int[] perm = new int[n+1];
		//we have n moves to find the largest number
		//then its EZ
		int biggest = 1;
		
		int[] ans = new int[n*2];
		int[] smallerThan = new int[n];
		int[] greaterThan = new int[n];
		ArrayList<Point>[] biggerThan = new ArrayList[n+1];
		for(int i = 1;i<=n;i++) {
			biggerThan[i] = new ArrayList<Point>();
		}
		for(int i = 1;i<=n;i++) {
			if(i==biggest)continue;
			System.out.println("? "+i+" "+biggest);
			System.out.flush();
			int k = scan.nextInt();
			
			System.out.println("? "+biggest+" "+i);
			System.out.flush();
			int k1 = scan.nextInt();
			
			ans[(i-2)*2] = k;
			ans[(i-2)*2+1]= k1;
			
			
			if(k>k1) {
				biggerThan[biggest].add(new Point(i,k));
			}
			else {
				biggerThan[i].add(new Point(biggest,k1));
				biggest = i;
			}
		}
		
		
		perm[biggest] = n;
		boolean[] v = new boolean[n+1];
		ArrayDeque<Integer> deq = new ArrayDeque<>();
		v[biggest] = true;
		deq.add(biggest);
		while(!deq.isEmpty()) {
			biggest = deq.poll();
			for(Point to:biggerThan[biggest]) {
				//we are bigger than all these indices
				//get the answer we had for to%biggest
				perm[to.idx] = to.val;
				v[to.idx] = true;
				deq.add(to.idx);
			}
		}
		System.out.print("! ");
		for(int i = 1;i<=n;i++) {
			System.out.print(perm[i]+" ");
		}
		System.out.flush();
		return;
	}
/*
3
0
1
2
1

 */
	static class Point{
		int idx, val;
		public Point(int a, int b) {
			idx = a;
			val = b;
		}
	}
	static class JS{
		public int BS = 1<<16;
		public char NC = (char)0;
		byte[] buf = new byte[BS];
		int bId = 0, size = 0;
		char c = NC;
		double num = 1;
		BufferedInputStream in;

		public JS() {
			in = new BufferedInputStream(System.in, BS);
		}

		public JS(String s) throws FileNotFoundException {
			in = new BufferedInputStream(new FileInputStream(new File(s)), BS);
		}

		public char nextChar(){
			while(bId==size) {
				try {
					size = in.read(buf);
				}catch(Exception e) {
					return NC;
				}				
				if(size==-1)return NC;
				bId=0;
			}
			return (char)buf[bId++];
		}

		public int nextInt() {
			return (int)nextLong();
		}

		public long nextLong() {
			num=1;
			boolean neg = false;
			if(c==NC)c=nextChar();
			for(;(c<'0' || c>'9'); c = nextChar()) {
				if(c=='-')neg=true;
			}
			long res = 0;
			for(; c>='0' && c <='9'; c=nextChar()) {
				res = (res<<3)+(res<<1)+c-'0';
				num*=10;
			}
			return neg?-res:res;
		}

		public double nextDouble() {
			double cur = nextLong();
			return c!='.' ? cur:cur+nextLong()/num;
		}

		public String next() {
			StringBuilder res = new StringBuilder();
			while(c<=32)c=nextChar();
			while(c>32) {
				res.append(c);
				c=nextChar();
			}
			return res.toString();
		}

		public String nextLine() {
			StringBuilder res = new StringBuilder();
			while(c<=32)c=nextChar();
			while(c!='\n') {
				res.append(c);
				c=nextChar();
			}
			return res.toString();
		}

		public boolean hasNext() {
			if(c>32)return true;
			while(true) {
				c=nextChar();
				if(c==NC)return false;
				else if(c>32)return true;
			}
		}
	}

}