#include <bits/stdc++.h>
using namespace std;
int main() {
  char s[25];
  int a, b;
  scanf("%d%d", &a, &b);
  scanf("%s", s);
  for (int i = a; i >= 0; i--) {
    if (!isdigit(s[i])) {
      puts("No");
      exit(0);
    }
  }
  if (s[a] != '-') {
    puts("No");
    exit(0);
  }
  for (int i = a + b + 1; i >= a + 1; i--) {
    if (!isdigit(s[i])) {
      puts("No");
      exit(0);
    }
  }
  puts("Yes");
  return 0;
}
