#Lutece0305. Luck

Luck

Migrated from Lutece 305 Luck

All parts of this problem, including description, images, samples, data and checker, might be broken. If you find bugs in this problem, please contact the admins.

Description

As we all know, Hongshu was awarded the title The Outstanding Student of UESTC(成电杰出学生). Surprisingly, he found that another outstanding student shares the same birthday with him. However, after carefully thinking, he realised that it is not a “small probability event”. Now, he wants to ask you, for NN people, what is probability of that there are at least two people share the same birthday. If two people share the same birthday, the month and day of their birthdays are the same respectively. (365365 days in a year in this problem).

Input

The first line of the input contains only one integer TT.

Then TT lines follow, every line contains only one integer NN (1N10001\leq N\leq 1000).

Output

For each test case, output one line. First ,output Case #C: , where CC is the number of test case, from 11 to TT.

Then,output the probability of that there were at least two people share the same birthday for those NN people, which should be printed accurately rounded to four decimals.

Samples

2
2
3
Case #1: 0.0027 
Case #2: 0.0082

Resources

love8909 & pfctgeorge