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