#include <stdio.h>
#include <malloc.h>
#include <stdlib.h>
struct Info {
int m;
int v;
double per;
};
int cmp(const void *a, const void *b);
int main() {
int n, t;
scanf("%d%d", &n, &t);
struct Info *info = (struct Info *)malloc(sizeof(struct Info) * n);
for (int i = 0; i < n; i++) {
scanf("%d%d", &info[i].m, &info[i].v);
info[i].per = (double)info[i].v / info[i].m;
}
qsort(info, n, sizeof(struct Info), cmp);
double cnt = 0;
int i;
for (i = 0; i < n && t - info[i].m >= 0; i++) {
cnt += info[i].v;
t -= info[i].m;
}
if (i < n)
cnt += t * info[i].per;
printf("%.2f", cnt);
return 0;
}
int cmp(const void *a, const void *b) {
return (*(struct Info *)b).per - (*(struct Info *)a).per;
}