#include <bits/stdc++.h>
using namespace std;
int main() {
  int a, b, i;
  bool good = true;
  string s;
  cin >> a >> b >> s;
  if ((s.size() != (a + b + 1)) or (s[a] != '-')) good = false;
  for (i = 0; i < s.size(); i++)
    if (i != a)
      if ((s[i] != '1') or (s[i] != '2') or (s[i] != '3') or (s[i] != '4') or
          (s[i] != '5') or (s[i] != '6') or (s[i] != '7') or (s[i] != '8') or
          (s[i] != '9') or (s[i] != '0'))
        good = true;
      else
        good = false;
  if (good == true)
    cout << "Yes";
  else
    cout << "No";
  system("pause");
  return 0;
}
