#include <bits/stdc++.h>
using namespace std;
int main() {
  string s;
  cin >> s;
  int flag = 0;
  int cur = 0;
  int ans = 0;
  for (int i = 0; i < s.size(); i++) {
    if (s[i] >= '0' && s[i] <= '9') {
      cur = cur * 10 + (s[i] - '0');
    } else {
      if (!flag) {
        ans += cur;
      } else {
        ans -= cur;
      }
      cur = s[i] - '0';
      if (s[i] == '+') {
        flag = 0;
      } else {
        flag = 1;
      }
    }
  }
  if (!flag)
    ans += cur;
  else
    ans -= cur;
  cout << ans << endl;
}
