#include <bits/stdc++.h>
using namespace std;
int main() {
  int a, b;
  string str;
  cin >> a >> b >> str;
  bool x = false;
  if (str.at(a) != '-') x = false;
  if (str.size() == a + b + 1) x = true;
  if (x == true) cout << "Yes" << endl;
  if (x == false) cout << "No" << endl;
}
