#include<bits/stdc++.h>
using namespace std;
#define rep(i,n) for(int i=0;i<n;i++)
main() {
	int a, b;
	cin >> a >> b;
	string s;
	cin >> s;
	bool flg = 1;
	if (s[a] == '-') {
		s.erase(a.begin() + a);
		rep(i, a + b) {
			if (!isdigit(s[i])) {
				flg = 0;
				break;
			}
		}

	}
	else {
		flg = 0;
	}
	if (flg) {
		cout << "Yes";

	}
	else {
		cout << "No";
	}

}