#include <bits/stdc++.h>
int main() {
  int a, b;
  scanf("%d%d", &a, &b);
  char s[a + b + 1];
  for (int i = 0; i < a + b + 1; i++) scanf("%c", &s[i]);
  if (s[a + 1] == '-') {
    printf("Yes\n");
  } else
    printf("No\n");
  return 0;
}
