#include <bits/stdc++.h>
int main(void) {
  int a, b, i;
  char s[15];
  scanf("%d %d", &a, &b);
  scanf("%s", s);
  for (i = 0; i < 10; i++)
    if (s[i] == '-') break;
  if (a == i && b == strlen(s) - i - 1)
    printf("Yes\n");
  else
    printf("No\n");
  return 0;
}
