#include <bits/stdc++.h>
using namespace std;
int main() {
  int a, b;
  string s;
  cin >> a >> b >> s;
  bool flg = true;
  if (s[a] != '-') flg = false;
  for (int i = a + 1; i < a + 1 + b; i++)
    if (s[i] < '0' || '9' < s[i]) flg = false;
  cout << (flg ? "Yes" : "No") << endl;
  return 0;
}
