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 CPP):

Solution:
#include <bits/stdc++.h>
using namespace std;
const double eps = 1e-9;
const double pi = acos(-1.0);
double w, h, angle;
inline int ID(const int i) {
  if (i < 0) return i + 4;
  if (i > 3) return i - 4;
  return i;
}
inline void extract(const pair<double, double> p1,
                    const pair<double, double> p2, double &a, double &b,
                    double &c) {
  a = p1.second - p2.second;
  b = p2.first - p1.first;
  c = -(a * p1.first + b * p1.second);
}
inline double eq(const pair<double, double> p, const double a, const double b,
                 const double c) {
  return a * p.first + b * p.second + c;
}
inline bool isIntersect(const pair<double, double> p11,
                        const pair<double, double> p12,
                        const pair<double, double> p21,
                        const pair<double, double> p22) {
  double a1, b1, c1, a2, b2, c2;
  extract(p11, p12, a1, b1, c1);
  extract(p21, p22, a2, b2, c2);
  double t11 = eq(p21, a1, b1, c1) > 0 ? 1 : -1;
  double t12 = eq(p22, a1, b1, c1) > 0 ? 1 : -1;
  double t21 = eq(p11, a2, b2, c2) > 0 ? 1 : -1;
  double t22 = eq(p12, a2, b2, c2) > 0 ? 1 : -1;
  return t11 * t12 < 0 && t21 * t22 < 0;
}
inline double Size(vector<pair<double, double> > s) {
  double ret = 0;
  s.push_back(s[0]);
  for (int i = 1; i < s.size(); i++)
    ret += (s[i].first - s[i - 1].first) * (s[i].second + s[i - 1].second);
  return abs(ret) / 2;
}
int main() {
  cin >> w >> h >> angle;
  if (w < h) swap(w, h);
  if (angle + 1e-9 > 90) angle = 180 - angle;
  if (abs(angle) < eps)
    cout << fixed << setprecision(10) << w * h;
  else if (abs(angle - 90) < eps)
    cout << fixed << setprecision(10) << h * h;
  else {
    angle = angle * pi / 180;
    pair<double, double> p[4] = {
        make_pair(-w / 2, -h / 2), make_pair(-w / 2, h / 2),
        make_pair(w / 2, h / 2), make_pair(w / 2, -h / 2)};
    double pd[4] = {-w / 2, h / 2, w / 2, -h / 2};
    pair<double, double> pp[4];
    for (int i = 0; i < 4; i++) {
      pp[i].first = cos(angle) * p[i].first - sin(angle) * p[i].second;
      pp[i].second = sin(angle) * p[i].first + cos(angle) * p[i].second;
    }
    vector<pair<double, double> > s;
    s.clear();
    for (int i = 0; i < 4; i++)
      for (int j = i - 2; j < i + 2; j++)
        if (isIntersect(pp[ID(i)], pp[ID(i + 1)], p[ID(j)], p[ID(j + 1)])) {
          double a, b, c;
          extract(pp[ID(i)], pp[ID(i + 1)], a, b, c);
          if (abs(j) % 2 == 0)
            s.push_back(make_pair(pd[ID(j)], -(a * pd[ID(j)] + c) / b));
          else
            s.push_back(make_pair(-(b * pd[ID(j)] + c) / a, pd[ID(j)]));
        }
    cout << fixed << setprecision(10) << Size(s);
  }
  return 0;
}