#include <iostream>
#include <string>
using namespace std;

int main() {
	int A, B;
	string S;
	cin >> A >> B;
	cin >> S;
	for (int i = 0; i < A+B+1; i++)
		if (i != A && S[i] == '-') {
			cout << "No\n";
			return 0;
		}
	if (S[A] == '-')
		cout << "Yes\n";
	else
		cout << "No\n";
}
