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