#include <bits/stdc++.h>
using namespace std;
int input_A, input_B = 0;
char input_S[11];
char output[4];
bool size, position = false;
int main() {
  cin >> input_A >> input_B;
  cin >> input_S;
  char output[4] = {'N', 'o', '\0'};
  int count = 0;
  for (int i = 0; sizeof(input_S); i++) {
    if (input_S[i] == '\0') {
      break;
    } else {
      count++;
    }
  }
  if (count == input_A + input_B + 1) {
    size = true;
  }
  if (input_S[input_A] == '-') {
    position = true;
  }
  if (size && position) {
    output[0] = {'Y'};
    output[1] = {'e'};
    output[2] = {'s'};
    output[3] = {'\0'};
  }
  cout << output << endl;
  return 0;
}
