#include <bits/stdc++.h>
using namespace std;
int main() {
  string a;
  cin >> a;
  string b = "";
  int ac, bc;
  ac = bc = 0;
  b = a;
  for (int i = 0; i < a.size(); i += 2) {
    if (b[i] == '+')
      b[i] = 'a';
    else
      b[i] = 'b';
    if (b[i] == 'a')
      ac++;
    else
      bc++;
  }
  for (int i = 1; i < a.size(); i += 2) {
    if (b[i] == '-')
      b[i] = 'a';
    else
      b[i] = 'b';
    if (b[i] == 'a')
      ac++;
    else
      bc++;
  }
  if (ac != bc) {
    cout << "No" << endl;
  } else
    cout << "Yes" << endl;
  return 0;
}
