#include <bits/stdc++.h>
int main() {
  char a[100];
  int x, y;
  scanf("%d%d", &x, &y);
  gets(a);
  if (a[x] != '-') {
    printf("No\n");
    return 0;
  }
  for (int i = 0; i < x; i++)
    if (!(a[i] >= '0' && a[i] <= '9')) {
      printf("No\n");
      return 0;
    }
  for (int i = x + 1; i <= y + 1; i++)
    if (!(a[i] >= '0' && a[i] <= '9')) {
      printf("No\n");
      return 0;
    }
  printf("Yes\n");
}
