#include <bits/stdc++.h>
using namespace std;
int main() {
  string S;
  cin >> S;
  if (S == "++++") {
    cout << 4 << endl;
  }
  if (S == "+++-") {
    cout << 2 << endl;
  }
  if (S == "++--") {
    cout << 0 << endl;
  }
  if (S == "+---") {
    cout << -1 << endl;
  }
  if (S == "---+") {
    cout << -1 << endl;
  }
  if (S == "--++") {
    cout << 0 << endl;
  }
  if (S == "-+++") {
    cout << 2 << endl;
  }
  if (S == "----") {
    cout << -4 << endl;
  }
  if (S == "+-+-") {
    cout << 0 << endl;
  }
  if (S == "-+-+") {
    cout << 0 << endl;
  }
  if (S == "+--+") {
    cout << 0 << endl;
  }
  if (S == "-++-") {
    cout << 0 << endl;
  }
  if (S == "++-+") {
    cout << 2 << endl;
  }
  if (S == "--+-") {
    cout << -2 << endl;
  }
  if (S == "-+--") {
    cout << -2 << endl;
  }
  if (S == "+-++") {
    cout << 2 << endl;
  }
}
