#include<bits/stdc++.h>
using namespace std;
int n,a,b,c,i,j,d;
string s;
int main()
{
  cin>>a>>b>>s;
  if(s[a]!='-')return cout<<"No"<<endl,0;
  for(;i<a;i++)if(s[i]=='-')return cout<<"No"<<endl,0;
  for(i=s.size()-b;i<s.size();i++)if(s[i]=='-')return cout<<"No"<<endl,0;
  cout<<"Yes"<<endl;
}