#include <bits/stdc++.h>
using namespace std;
const double pi = acos(-1.0);
const double eps = 1e-8;
const long long inf = 0x3f3f3f3f;
const long long maxn = 1e5 + 7;
const long long mod = 1e9 + 7;
long long ksm(long long a, long long b) {
  long long ans = 1LL;
  while (b > 0) {
    if (b & 1LL) ans = ans * a % mod;
    a = a * a % mod;
    b /= 2LL;
  }
  return ans;
}
long long getnum(long long& th, string& s) {
  long long ans = th > 0 ? (s[th - 1] - '0') : 0;
  while (s[th] <= '9' && s[th] >= '0') {
    ans *= 10;
    ans += s[th++] - '0';
  }
  while (s[th] == ' ') th++;
  return ans;
}
long long getv(long long& th, string& s, long long flag) {
  while (s[th] == ' ') th++;
  long long pre = 0;
  pre = getnum(th, s);
  pre *= flag;
  while (s[th] == ' ') th++;
  if (s[th] == '+') {
    th++;
    return pre + getv(th, s, 1);
  } else if (s[th] == '-') {
    th++;
    return pre + getv(th, s, -1);
  }
  return pre;
}
signed main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  string s;
  cin >> s;
  long long ans = 0;
  long long th = 0;
  ans = getv(th, s, 1);
  printf("%lld\n", ans);
  return 0;
}
