#include <bits/stdc++.h>
using namespace std;
using LL = int64_t;
const int INF = 0x3f3f3f3f;
int main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  int a, b;
  string s;
  cin >> a >> b >> s;
  int flag = 0;
  for (int i = 0; i < s.length(); i++) {
    if (i < a && s[i] >= '0' && s[i] <= '9')
      continue;
    else if (i == a && s[i] == '-')
      continue;
    else if (i > a && i < b && s[i] >= '0' && s[i] <= '9')
      continue;
    else
      flag = 1;
  }
  if (flag == 1)
    cout << "No\n";
  else
    cout << "Yes\n";
  return 0;
}
