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