Bizon the Champion isn't just charming, he also is very smart.

While some of us were learning the multiplication table, Bizon the Champion had fun in his own manner. Bizon the Champion painted an n × m multiplication table, where the element on the intersection of the i-th row and j-th column equals i·j (the rows and columns of the table are numbered starting from 1). Then he was asked: what number in the table is the k-th largest number? Bizon the Champion always answered correctly and immediately. Can you repeat his success?

Consider the given multiplication table. If you write out all n·m numbers from the table in the non-decreasing order, then the k-th number you write out is called the k-th largest number.

Input

The single line contains integers n, m and k (1 ≤ n, m ≤ 5·105; 1 ≤ k ≤ n·m).

Output

Print the k-th largest number in a n × m multiplication table.

Examples

Input

2 2 2


Output

2


Input

2 3 4


Output

3


Input

1 10 5


Output

5

Note

A 2 × 3 multiplication table looks like this:
    
    
      
    1 2 3  
    2 4 6  
      
    


import java.io.BufferedWriter;
import java.io.FileInputStream;
import java.io.FileNotFoundException;
import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;
import java.io.OutputStreamWriter;
import java.io.PrintWriter;
import java.util.ArrayList;
import java.util.InputMismatchException;
import java.util.LinkedList;

public class P1 {

	static long n, m;
	static long from, to;
	static boolean exists;

	public static void main(String[] args) {
		FastScanner scanner = new FastScanner();
		n = scanner.nextInt();
		m = scanner.nextInt();
		long k = scanner.nextLong();
		long low = 1;
		long high = m * n;

		while (true) {
			long mid = (low + high) / 2;
			//System.out.println(low + " " + high + " " + mid);
			from = 0;
			to = 0;
			setFromAndTo(mid);
			//System.out.println("[" + from + ", " + to + "]");
			if (k >= from && k <= to) {
				System.out.println(mid);
				break;
			}

			else if (k < from) {
				//System.out.println("k<from");
				high = (exists ? mid - 1 : mid);
			}
			else {
				//System.out.println("k>from");
				low = mid + 1;
			}
		}

	}

	static void setFromAndTo(long number) {

		int occurances = 0;
		for (long i = 1; i <= m; i++) {
			long low = 1, high = n;
			if (n * i < number) {
				from += n;
				continue;
			}
			from+=(number-1)/i;
			if(number%i==0)
				occurances++;
		}
		if (occurances == 0) {
			exists = false;
		}
		from++;
		to = from + occurances - 1;
	}

}

class FastScanner {

	private InputStream stream;
	private byte[] buf = new byte[1024];
	private int curChar;
	private int numChars;

	public FastScanner() {
		this.stream = System.in;
	}

	public FastScanner(InputStream stream) {
		this.stream = stream;
	}

	public FastScanner(String fileName) {
		try {
			this.stream = new FileInputStream(fileName);
		} catch (FileNotFoundException e) {
			e.printStackTrace();
		}
	}

	public int nextChar() {
		if (numChars == -1)
			throw new InputMismatchException();
		if (curChar >= numChars) {
			curChar = 0;
			try {
				numChars = stream.read(buf);
			} catch (IOException e) {
				throw new InputMismatchException();
			}
			if (numChars <= 0)
				return -1;
		}
		return buf[curChar++];
	}

	public int nextInt() {
		int c = nextChar();
		while (isSpaceChar(c))
			c = nextChar();
		int sgn = 1;
		if (c == '-') {
			sgn = -1;
			c = nextChar();
		}
		int res = 0;
		do {
			if (c < '0' || c > '9')
				throw new InputMismatchException();
			res *= 10;
			res += c - '0';
			c = nextChar();
		} while (!isSpaceChar(c));
		return res * sgn;
	}

	public long nextLong() {
		int c = nextChar();
		while (isSpaceChar(c))
			c = nextChar();
		int sgn = 1;
		if (c == '-') {
			sgn = -1;
			c = nextChar();
		}
		long res = 0;
		do {
			if (c < '0' || c > '9')
				throw new InputMismatchException();
			res *= 10;
			res += c - '0';
			c = nextChar();
		} while (!isSpaceChar(c));
		return res * sgn;
	}

	public String readString() {
		int c = nextChar();
		while (isSpaceChar(c))
			c = nextChar();
		StringBuilder res = new StringBuilder();
		do {
			res.appendCodePoint(c);
			c = nextChar();
		} while (!isSpaceChar(c));
		return res.toString();
	}

	private boolean isSpaceChar(int c) {
		return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
	}

	public String next() {
		return readString();
	}
}

class OutputWriter {
	private PrintWriter writer;

	public OutputWriter() {
		writer = new PrintWriter(new BufferedWriter(new OutputStreamWriter(System.out)));
	}

	public OutputWriter(OutputStream outputStream) {
		writer = new PrintWriter(new BufferedWriter(new OutputStreamWriter(outputStream)));
	}

	public OutputWriter(String fileName) {
		try {
			writer = new PrintWriter(fileName);
		} catch (FileNotFoundException e) {
			e.printStackTrace();
		}
	}

	public void print(String s) {
		writer.print(s);
	}

	public void println(String s) {
		writer.println(s);
	}

	public void close() {
		writer.close();
	}

	public void flush() {
		writer.flush();
	}
}