Problem: Flatland has recently introduced a new type of an eye check for the driver's licence. The check goes like that: there is a plane with mannequins standing on it. You should tell the value of the minimum angle with the vertex at the origin of coordinates and with all mannequins standing inside or on the boarder of this angle. 

As you spend lots of time "glued to the screen", your vision is impaired. So you have to write a program that will pass the check for you.

Input

The first line contains a single integer n (1 ≤ n ≤ 105) — the number of mannequins.

Next n lines contain two space-separated integers each: xi, yi (|xi|, |yi| ≤ 1000) — the coordinates of the i-th mannequin. It is guaranteed that the origin of the coordinates has no mannequin. It is guaranteed that no two mannequins are located in the same point on the plane.

Output

Print a single real number — the value of the sought angle in degrees. The answer will be considered valid if the relative or absolute error doesn't exceed 10 - 6. 

Examples

Input

2
2 0
0 2


Output

90.0000000000


Input

3
2 0
0 2
-2 2


Output

135.0000000000


Input

4
2 0
0 2
-2 0
0 -2


Output

270.0000000000


Input

2
2 1
1 2


Output

36.8698976458

Note

Solution for the first sample test is shown below: 

<image>

Solution for the second sample test is shown below: 

<image>

Solution for the third sample test is shown below: 

<image>

Solution for the fourth sample test is shown below: 

<image>

Solution (in JAVA):

Solution:
// practice with kaiboy
import java.io.*;
import java.util.*;

public class CF257C extends PrintWriter {
	CF257C() { super(System.out, true); }
	Scanner sc = new Scanner(System.in);
	public static void main(String[] $) {
		CF257C o = new CF257C(); o.main(); o.flush();
	}

	static class P {
		int x, y;
		P(int x, int y) {
			this.x = x; this.y = y;
		}
	}
	int cross(P p, P q) {
		return p.x * q.y - p.y * q.x;
	}
	int dist2(int x, int y) {
		return x * x + y * y;
	}
	int gcd(int a, int b) {
		return b == 0 ? a : gcd(b, a % b);
	}
	void main() {
		int n = sc.nextInt();
		P[] pp = new P[n];
		for (int i = 0; i < n; i++) {
			int x = sc.nextInt();
			int y = sc.nextInt();
			int d = gcd(Math.abs(x), Math.abs(y)); x /= d; y /= d;
			pp[i] = new P(x, y);
		}
		Arrays.sort(pp, (p, q) -> {
			int sp = p.y > 0 || p.y == 0 && p.x > 0 ? 1 : -1;
			int sq = q.y > 0 || q.y == 0 && q.x > 0 ? 1 : -1;
			return sp != sq ? sp - sq : cross(p, q);
		});
		int n_ = 1;
		for (int i = 1; i < n; i++) {
			P p = pp[i - 1], q = pp[i];
			if (!(p.x == q.x && p.y == q.y))
				pp[n_++] = q;
		}
		n = n_;
		if (n == 1) {
			println(0);
			return;
		}
		double theta_ = 0;
		for (int i = 0; i < n; i++) {
			P p = pp[i], q = pp[(i + 1) % n];
			double op = Math.hypot(p.x, p.y);
			double oq = Math.hypot(q.x, q.y);
			int c = cross(q, p);
			double theta = Math.asin(Math.abs(c) / (op * oq));
			if (dist2(p.x - q.x, p.y - q.y) > dist2(p.x, p.y) + dist2(q.x, q.y))
				theta = Math.PI - theta;
			if (c < 0)
				theta = Math.PI * 2 - theta;
			theta_ = Math.max(theta_, theta);
		}
		println((Math.PI * 2 - theta_) / Math.PI * 180);
	}
}