#include <iostream>
#include <math.h>
#include <vector>
#include <queue>
using namespace std;
struct node
{
vector<int> children;
};
int n;
double p,r;
vector<node> C;
int cnt=1,min_depth=99999999;
void dfs(int root,int depth){//按层访问
if(depth>min_depth) return;//大于当前最小深度,则不必继续
if(C[root].children.size()==0){//叶结点
if(depth<min_depth){
min_depth=depth;
cnt=1;
}else if(depth==min_depth){
cnt++;
}
}
for(int i=0;i<C[root].children.size();i++){
dfs(C[root].children[i],depth+1);
}
}
int main(){
scanf("%d %lf %lf",&n,&p,&r);
C.resize(n);
int tn,t;
for(int i=0;i<n;i++){
scanf("%d",&tn);
if(tn>0){
while(tn--){
scanf("%d",&t);
C[i].children.push_back(t);
}
}
}
dfs(0,0);
printf("%.4f %d",p*pow(1+0.01*r,min_depth),cnt);
return 0;
}