Problem: You are given two rectangles on a plane. The centers of both rectangles are located in the origin of coordinates (meaning the center of the rectangle's symmetry). The first rectangle's sides are parallel to the coordinate axes: the length of the side that is parallel to the Ox axis, equals w, the length of the side that is parallel to the Oy axis, equals h. The second rectangle can be obtained by rotating the first rectangle relative to the origin of coordinates by angle α.

<image>

Your task is to find the area of the region which belongs to both given rectangles. This region is shaded in the picture.

Input

The first line contains three integers w, h, α (1 ≤ w, h ≤ 106; 0 ≤ α ≤ 180). Angle α is given in degrees.

Output

In a single line print a real number — the area of the region which belongs to both given rectangles.

The answer will be considered correct if its relative or absolute error doesn't exceed 10 - 6.

Examples

Input

1 1 45


Output

0.828427125


Input

6 4 30


Output

19.668384925

Note

The second sample has been drawn on the picture above.

Solution (in JAVA):

Solution:
import java.util.*;
import java.io.*;

public class RectanglePuzzle{

	public static void main(String[] args){
		Scanner scan = new Scanner(System.in);
		double w = scan.nextDouble();
		double h = scan.nextDouble();
		double ang = scan.nextDouble()*Math.PI/180;
		Vec[] a = new Vec[]{new Vec(w/2, h/2), new Vec(-w/2, h/2), new Vec(-w/2, -h/2), new Vec(w/2, -h/2)};
		Vec[] b = new Vec[4];
		for(int i = 0; i < 4; i++)
			b[i] = new Vec(a[i].x*Math.cos(ang)-a[i].y*Math.sin(ang), a[i].x*Math.sin(ang)+a[i].y*Math.cos(ang));
		
		Vec[] poly = a;
		for(int i = 0; i < 4; i++)
			poly = clip(poly, new Seg(b[i], b[(i+1)%4]));
		
		double area = 0;
		for(int i = 0; i < poly.length; i++){
			Vec aa = poly[i];
			Vec bb = poly[(i+1)%poly.length];
			area += (bb.x-aa.x)*(bb.y+aa.y);
		}
		System.out.println(Math.abs(area/2));
	}

	static Vec[] clip(Vec[] poly, Seg line){
		ArrayList<Vec> toReturn = new ArrayList<>();
		int nLeft = 0, nRight = 0, n = poly.length;
		int[] side = new int[n];
		for(int i = 0; i < n; i++){
			side[i] = line.side(poly[i]);
			if(side[i] == 1) nLeft++;
			if(side[i] == -1) nRight++;
		}
		if(nLeft == 0) return new Vec[0];
		if(nRight == 0) return poly;

		for(int i = 0; i < n; i++){
			int next = (i+1)%n;
			if(side[i] == 1) toReturn.add(poly[i]);
			if(side[i]*side[next] != 1){
				Vec intersect = line.lineIntersect(new Seg(poly[i], poly[next]));
				if(intersect != null)
					toReturn.add(intersect);
			}
		}
		Vec[] res = new Vec[toReturn.size()];
		for(int i = 0; i < res.length; i++)
			res[i] = toReturn.get(i);
		return res;
	}

	static class Vec{

		double x;
		double y;

		public Vec(double xx, double yy){
			x = xx;
			y = yy;
		}

		public Vec add(Vec v){
			return new Vec(x+v.x, y+v.y);
		}

		public Vec sub(Vec v){
			return new Vec(x-v.x, y-v.y);
		}

		public Vec scale(double t){
			return new Vec(x*t, y*t);
		}

		public double mag(){
			return Math.sqrt(x*x+y*y);
		}

		public Vec unit(){
			return this.scale(this.mag());
		}

		public double cross(Vec v){
			return x*v.y-y*v.x;
		}
		
		public static boolean eq(double a, double b){
			return Math.abs(a-b) < 1e-6;
		}
	}

	static class Seg{

		Vec from, to, dir;

		public Seg(Vec from, Vec to){
			this.from = from;
			this.to = to;
			dir = to.sub(from);
		}

		public Vec lineIntersect(Seg o){
			double det = o.dir.x*dir.y-dir.x*o.dir.y;
			if(Vec.eq(det,0)) return null;
			double dist = (o.dir.x*(o.from.y-from.y)-
							o.dir.y*(o.from.x-from.x))/det;
			return from.add(dir.scale(dist));
		}

		public int side(Vec o){
			Vec oDir = o.sub(from);
			double distFromLine = dir.unit().cross(oDir);
			if(Vec.eq(distFromLine, 0)) return 0;
			return (int)Math.signum(distFromLine);
		}
	}
}