#include <bits/stdc++.h>
using namespace std;
int a, b, sum;
string s;
int main() {
  scanf("%d%d", &a, &b);
  scanf("%s", &s);
  for (int i = a + 2; i < a + b + 1; i++)
    if (s[i] >= '0' && s[i] <= '9') sum++;
  if (sum != a + b + 1 - a + 2)
    printf("No\n");
  else if (s[a + 1] == '-')
    printf("No\n");
  else
    printf("Yes\n");
  return 0;
}
