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