N,T=map(int,input().split())
weight={}
average=[]
for i in range(N):
m,v=map(int,input().split())
a=v/m
if a not in average:
average.append(a)
if a not in weight:
weight[a]=m
else:
weight[a]+=m
sorted(average)[::-1]
left=T
money=0
for i in average:
if weight[i]<=left:
money+=weight[i]*i
left-=weight[i]
else:
money+=i*left
break
print('%.2f'%money)