#include <bits/stdc++.h>
using namespace std;
int main() {
  int A, B;
  char S[12];
  cin >> A;
  cin >> B;
  cin >> S;
  for (int i = 0; i <= A; i++)
    if (!('0' <= S[0] && '9' >= S[i])) cout << "No";
  if (S[A] != '-') cout << "No";
  for (int i = A + 1; i <= A + B + 1; i++)
    if (!('0' <= S[0] && '9' >= S[i])) cout << " No";
  cout << "Yes";
}
