#include <bits/stdc++.h>
using namespace std;
char s[128];
int main() {
  scanf("%s", s);
  int sum = 0;
  for (int i = 0; s[i];) {
    int d = s[i] - '0';
    int sg = (s[i] == '-') ? -1 : 1;
    i++;
    while (s[i] >= '0' && s[i] <= '9') d = d * 10 + (s[i++] - '0');
    sum += sg * d;
  }
  printf("%d\n", sum);
  return 0;
}
