#include "bits/stdc++.h"
using namespace std;
typedef long long ll;
typedef long double ld;
#define REP(i, a, b) for(ll i = ll(a); i <= ll(b); i++)
int main()
{
	ll a,b,x;
	cin>>a>>b;
	string s;
	cin>>s;
	REP(i,0,a-1)
	{		
		if(!('0'<=s[i]&&s[i]<='9'))
		{
			cout<<"No";	return 0;
		}
		x=i;
	}	
	if(s[a]!='-')
	{
		cout<<"No";
		return 0;
	}
	REP(j,a+1,j<a+b)
	{
		if(!('0'<=s[i]&&s[i]<='9'))
		{
			cout<<"No";
			return 0;
		}
	}	
	cout<<"Yes";
}