// editor3
#include<stdio.h>
typedef struct orderdetails{
    char name[30];
    int id;
    float price;
}details;
int main(){
    int n,ind,amt=0;
    if(!scanf("%d",&n)|| n<0){
        printf("Invalid input");
    }
    details det[n];
    for(ind = 0;ind<n;ind++){
        scanf("%s",&det[ind].name);
        scanf("%d",&det[ind].id);
        scanf("%d",&det[ind].price);
    }
    
    for(ind = 0;ind<n;amt = amt + det[ind].price);
    printf("%.2f",amt);
    
    
}