#include #include #include using namespace std; #define E 10000000000 typedef long long int ll; int main(){ int n; cin>>n; string a; ll sei=0,syo=0; for(int i=0;i>a; ll tsei=0,tsyo=0; int syocnt=0; bool plus=true,seisyo=true; for(int j=0;j<(int)a.size();j++){ if(a[j]=='.') seisyo=false; else if(a[j]=='-') plus=false; else{ if(seisyo) tsei=tsei*10+(ll)(a[j]-'0'); else{ tsyo=tsyo*10+(ll)(a[j]-'0'); syocnt++; } } } for(int j=syocnt;j<10;j++) tsyo*=10; if(plus){ syo+=tsyo; sei+=tsei+(syo/E); syo%=E; } else{ syo-=tsyo; if(syo<0){ sei--; syo+=E; } sei-=tsei; } } if(syo>0&&sei<0){ sei++; syo-=E; syo*=-1; } printf("%lld.%010lld\n",sei,syo); return 0; }