#include <bits/stdc++.h>
using namespace std;
int A, B;
bool flag = true;
string a;
int main() {
  cin >> A >> B >> a;
  if (A + B + 1 != a.length()) flag = false;
  if (flag) {
    for (int i = 0; i < A; i++) {
      int x = (a[i] == '-' ? 10 : a[i] - '0');
      if (!(0 <= x && x <= 9)) return flag = false;
    }
    if (a[A] != '-') return flag = false;
    for (int i = A + 1; i < A + B + 1; i++) {
      int x = (a[i] == '-' ? 10 : a[i] - '0');
      if (!(0 <= x && x <= 9)) return flag = false;
    }
  }
  if (flag)
    puts("Yes");
  else
    puts("No");
  return 0;
}
