#include <bits/stdc++.h>
using namespace std;
inline int read() {
  char c;
  int s = 0, t = 1;
  while (!isdigit(c = getchar()))
    if (c == '-') t = -1;
  do {
    s = s * 10 + c - '0';
  } while (isdigit(c = getchar()));
  return s * t;
}
inline long long readl() {
  char c;
  long long s = 0;
  int t = 1;
  while (!isdigit(c = getchar()))
    if (c == '-') t = -1;
  do {
    s = s * 10 + c - '0';
  } while (isdigit(c = getchar()));
  return s * t;
}
int n, m;
int main() {
  char a[100];
  n = read(), m = read();
  scanf("%s", a + 1);
  for (int i = 1; i <= n + m + 1; i++) {
    if (a[i] == '-') {
      if (i - 1 == n) {
        printf("Yes\n");
        return 0;
      } else
        break;
    }
  }
  printf("No\n");
}
