#include <bits/stdc++.h>
int main() {
  char s1[200];
  scanf("%s", &s1);
  int n, a = 0, b = 0, i;
  n = strlen(s1);
  for (i = 0; i < n; i++) {
    if (s1[i] == 'o') {
      a++;
    }
    if (s1[i] == '-') {
      b++;
    }
  }
  if (b == 0 || a == 0) {
    printf("YES");
  } else if (b % a == 0) {
    printf("YES");
  } else {
    printf("NO");
  }
}
