a1/sum
#include<cstdio>
#include<iostream>
#include<algorithm>
#include<cstring>
#include<cmath>
#include<queue>
#include<map>
using namespace std;
#define MOD 1000000007
const int INF=0x3f3f3f3f;
const double eps=1e-;
typedef long long ll;
#define cl(a) memset(a,0,sizeof(a))
#define ts printf("*****\n");
const int MAXN=;
int n,m,tt;
int a[MAXN];
int main()
{
int i,j,k,ca=;
#ifndef ONLINE_JUDGE
freopen("1.in","r",stdin);
#endif
scanf("%d",&tt);
while(tt--)
{
cin>>n;
int w,sum=;
printf("Case %d: ",ca++);
for(i=;i<n;i++)
{
int a;
scanf("%d",&a);
if(i==) w=a;
sum+=a;
}
printf("%.6lf\n",(double)w/sum);
}
}