#include <bits/stdc++.h>
using namespace std;
int main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  string s;
  cin >> s;
  int o = 0, k = 0;
  for (int i = 0; i < s.size(); i++) {
    o += s[i] == 'o';
    k += s[i] == '-';
  }
  if (o == 0)
    puts("YES");
  else if (k % (o) == 0)
    puts("YES");
  else
    puts("NO");
  return 0;
}
