#include"bits/stdc++.h"
using namespace std;
int main(){
	int a,b;
	cin>>a>>b;
	string s;
	bool ch=true;
	cin>>s;
	for(int i=0;i!=s.size();++i){
		if(i!=a && !isdigit(s[i]))
			ch=false;
	}
	if(s[a]!='-')
		ch=false;
	cout<<(ch ? "Yes":"No");
}