#include <bits/stdc++.h>
using namespace std;
const int maxn = 1e5 + 10;
char a[105];
int main() {
  int x, y;
  int f = 0;
  scanf("%d%d", &x, &y);
  scanf("%s", a);
  if (strlen(a) != x + y + 1) f = 0;
  for (int i = 0; a[i]; i++) {
    if (a[x] != '-') f = 0;
    if (i != x && !isdigit(a[i])) f = 0;
  }
  if (f)
    puts("Yes");
  else
    puts("No");
  return 0;
}
