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