Points on a Circle

Given n random points on a unit circle and an angle p, compute -log2 of the probability that all n points fit inside some arc of central angle p.

Hard8ProbabilityMathCombinatoricsImplementationNo attempts yetTime limit2sMemory limit512 MB

Problem

You place nn points at random on the circumference of a circle of radius 1. Each point is equally likely to land anywhere on the circumference.

Let PP be the probability that all nn points lie on one arc of that same circle whose central angle is at most pp degrees. The arc may begin at any point of the circumference.

Because PP can be extremely small, print log2P-\log_2 P instead of PP.

Input

The first line contains the number of points nn and the angle pp. (1n1000001 \le n \le 100000, 1p<1801 \le p < 180)

Both nn and pp are positive integers.

Output

Print log2P-\log_2 P with exactly six digits after the decimal point, rounded at the seventh digit.