#include <bits/stdc++.h>
int main() {
  int a, b;
  bool print;
  scanf("%d %d", &a, &b);
  char str[a + b + 1];
  scanf("%s", &str);
  for (int i = 0; str[i] != '\0'; i++) {
    if (str[i] >= '0' && str[i] <= '9' || str[i] == '-') {
      print = true;
      if (str[a] == '-') {
        print = true;
      }
      if (str[a] != '-') {
        print = false;
      }
    } else {
      print = false;
    }
  }
  if (print = true) {
    printf("Yes\n");
  }
  if (print = false) {
    printf("No\n");
  }
  return 0;
}
