#include<iostream>
#include<string>
using namespace std;

int main(){
  	int A,B;
	string s;
  	cin>>A>>B>>s;
  	if(s[A]!='-'){cout<<"No"<<endl;return 0;}
	for(int i=0;i<s.size();++i){
    	if(i!=A&&s[i]=='-'){cout<<"No"<<endl;return 0;}
    }cout<<"Yes"<<endl;
  	return 0;
}
