#include <iostream>
#include<sstream>
#include<vector>
#include<iterator>
#include<alforithm>
using namespace std;

int main(void)
{
	int A, B;
	cin >> A >> B;

	string S;
	cin >> S;

	const string num = "0123456789";
	string ret = "Yes";
	for(int i=0; i<S.size(); i++){
		if(i == A){
			if(S[i] != '-')
				ret = "No";
		}
		else if(find(num.begin(), num.end(), S[i]) == num.end())
			ret = "No";
	}

	cout << ret << endl;

	return 0;
}
