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:
import java.util.*;
import java.io.*;
import java.util.AbstractMap.*;

public class C257 {
	
	public static void main(String args[]) throws Exception {

		InputReader reader = new InputReader(System.in);
		PrintWriter out = new PrintWriter(new BufferedWriter(new OutputStreamWriter(System.out)));
		

		int n = reader.I();
		Integer coords[][] = new Integer[n][2];
		for(int i=0;i<n;i++) {
			coords[i][0] = reader.I();
			coords[i][1] = reader.I();
		}
		Arrays.sort(coords, (v1, v2) -> {
			return (int) Math.signum(Math.atan2(v1[1], v1[0]) - Math.atan2(v2[1], v2[0]));
		});
		double maxAngle = 0;
		for(int i=0;i<n;i++) {
			int next = (i+1)%n;
			double angle = Math.atan2(coords[i][1], coords[i][0]);
			double angle2 = Math.atan2(coords[next][1], coords[next][0]);
			if(angle2 < angle) angle2+= 2*Math.PI;
			double diff = angle2 - angle;
			//out.println(String.format("%.8f", Math.toDegrees(diff)));
			//out.println(diff);
			maxAngle = Math.max(maxAngle, diff);
			//out.println(String.format("%.8f", Math.toDegrees(maxAngle)));
		}
		//out.println(maxAngle);
		//out.println(String.format("%.8f", Math.toDegrees(maxAngle)));
		if(maxAngle < 0.0001) out.print(0);
		else
		out.print(String.format("%.8f", 360.0-Math.toDegrees(maxAngle)));
		out.close();
	}
        
	

	static BufferedReader br;
    static long M = (long) 1e9 + 7;

    static class InputReader {
        public BufferedReader reader;
        public StringTokenizer tokenizer;

        public InputReader(InputStream stream) {
            reader = new BufferedReader(new InputStreamReader(stream), 32768);
            tokenizer = null;
        }

        public String next() {
            while (tokenizer == null || !tokenizer.hasMoreTokens()) {
                try {
                    tokenizer = new StringTokenizer(reader.readLine());
                } catch (IOException e) {
                    throw new RuntimeException(e);
                }
            }
            return tokenizer.nextToken();
        }

        public int I() {
            return Integer.parseInt(next());
        }

    }
}