#include<iostream>
#include<string>
using namespace std;
string S;
int A,B;
int main(void){
	cin>>A>>B>>S;
	if(S[A]!='-'){
		cout<<"No";
		return 0;
	}
	for(int i=0;i<S.size();i++)
		if((S[i]>'9'||S[i]<'0')&&i!=A){
			cout<<"No";
			return 0;
		}
	cout<<"Yes";
	return 0;
}