#include <bits/stdc++.h>
using namespace std;
string s;
bool p = 1;
int co, x;
int main() {
  cin >> s;
  for (int i = 0; i < s.size(); i++) {
    if (s[i] >= '0' && s[i] <= '9')
      x = (s[i] - 48) + x * 10;
    else {
      if (p)
        co += x;
      else
        co -= x;
      x = s[i] - 48;
      if (s[i] == '+')
        p = 1;
      else
        p = 0;
    }
  }
  if (p)
    co += x;
  else
    co -= x;
  cout << co;
}
