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