#include<iostream>
using namespace std;
int main(){
	int a,b; cin >> a >> b;
	string s;
	cin >> s;
	bool ans=true;
	for(int i=0;i<s.length();i++){
		if(i!=a){
			if(s[i]=='-') ans=false;
		}else{
			if(s[i]!='-') ans=false;
		}
	}
	if(ans) cout << "Yes" << endl;
	else cout << "No" << endl;
		
}
