#include <iostream>
#include <math.h>
using namespace std;
int main() {
int n;
double a, S=0;
cin >> n;
for(int i=1; i<=n; i++)
{
cin >> a;
S+=fabs(a);
}
cout << S;
return 0;
}
I2luY2x1ZGUgPGlvc3RyZWFtPgojaW5jbHVkZSA8bWF0aC5oPgp1c2luZyBuYW1lc3BhY2Ugc3RkOwoKaW50IG1haW4oKSB7CglpbnQgbjsgCglkb3VibGUgYSwgUz0wOwoJY2luID4+IG47CiAgCWZvcihpbnQgaT0xOyBpPD1uOyBpKyspCiAgCXsKCQljaW4gPj4gYTsKCQlTKz1mYWJzKGEpOwogIAl9Cgljb3V0IDw8IFM7CglyZXR1cm4gMDsKfQ==