|시간 제한||메모리 제한||제출||정답||맞은 사람||정답 비율|
|20 초 (추가 시간 없음)||1024 MB (추가 메모리 없음)||4||3||3||100.000%|
You're playing a card game as a single player.
There are N cards. The i-th card has integer i written on it.
You first shuffle N cards randomly and put them in a pile. Take the card at the top of the pile to your hand. Then repeat the following process until the pile becomes empty:
The score of the game is the number of cards in your hand at the end. With the given number of cards N, what is the expected score of the game?
The first line of the input contains the number of test cases, T. T lines follow. Each line contains a single integer N, the number of cards in the pile.
For each test case, output one line containing
Case #x: y, where
x is the test case number (starting from 1) and
y is the expected score at the end of the game.
y will be considered correct if it is within an absolute or relative error of 10-6 of the correct answer.
2 1 2
Case #1: 1.0 Case #2: 1.5