#include <bits/stdc++.h>
using namespace std;
int n, m;
int main() {
  int a, b;
  cin >> a >> b;
  char s[13];
  cin >> s;
  bool f = true;
  int i;
  for (i = 0; i < a; i++) {
    if (s[i] >= '0' && s[i] <= '9')
      continue;
    else
      f = false;
  }
  if (s[i++] != '-') f = false;
  for (; i < b; i++) {
    if (s[i] >= '0' && s[i] <= '9')
      continue;
    else
      f = false;
  }
  if (!f)
    puts("No");
  else
    puts("Yes");
  return 0;
}
