#include<cstdio>
using namespace std;
int main(){
  int a, b; scanf("%d%d",&a,&b);
  char s[a+b+1]; scanf("%s", &s)
  for(int i = 0; i < a; i++){
    if(!('0' <= s[i] && s[i] <= '9')) puts("No");
  }

  if(s[a] != '-') puts("No");
  for(int j = a+1; j <= a+b; j++) if(!('0' <= s[j] && s[j] <= '9'))
  {
    puts("No");
  }
  puts("Yes");  
}