#include <bits/stdc++.h>
using namespace std;
const int INF = 1001001001;
int main() {
  int a, b;
  char s[12];
  cin >> a >> b >> s;
  for (int i = 0; i < a; i++)
    if (!('0' <= s[i] && s[i] <= '9')) puts("No");
  if (s[a] != '-') ("No");
  for (int i = a + 1; i < b; i++)
    if (!('0' <= s[i] && s[i] <= '9')) puts("No");
  puts("Yes");
}
