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