#include<iostream>
using namespace std;
int main(){
  int a,b,f=1;
  cin>>a>>b;
  string s;
  cin>>s;
  int i;
  for(i=0;i<a;i++)if(s[i]<'0'||s[i]>'9')f=0;
  if(s[i]!='-')f=0;
  for(i=a+1;i<a+b+1;i++)if(s[i]<'0'||s[i]>'9')f=0;
  if(f==1)cout<<"Yes"<<endl;
  else cout<<"No"<<endl;
}