#include <bits/stdc++.h>
#pragma GCC optimize("O3")
using namespace std;
long long GCD(long long a, long long b) { return b ? GCD(b, a % b) : a; }
long long LCM(long long a, long long b) { return a / GCD(a, b) * b; }
int dx[4] = {-1, 0, 1, 0};
int dy[4] = {0, -1, 0, 1};
char dir[4] = {'u', 'l', 'd', 'r'};
long long int cmp1(pair<long long int, string> a,
                   pair<long long int, string> b) {
  if (a.first != b.first)
    return a.first < b.first;
  else
    return a.second < b.second;
}
int main() {
  cin.tie(0);
  ios::sync_with_stdio(false);
  int a, b;
  cin >> a >> b;
  string s;
  cin >> s;
  int n = s.length();
  int cnt = 0;
  for (int i = 1; i < s.length() - 1; i++) {
    if (s[i] == '-') cnt++;
  }
  if (s[0] == '-' || s[n - 1] == '-') {
    cout << "No" << endl;
    return 0;
  }
  for (int i = 0; i < n; i++) {
    if (s[i] != '-' && s[i] < '0' && s[i] > '9') {
      cout << "No" << endl;
      return 0;
    }
  }
  if (cnt == 1)
    cout << "Yes" << endl;
  else
    cout << "No" << endl;
  return 0;
}
