#include <iostream>
#include <string>
#include <algorithm>
#define rep(i, n) for(i = 0; i < n; i++)
#define rrep(i, n) for(i = n - 1; i >= 0; i--)
using namespace std;

int main() {
        int a,b;
        string s;
	cin >> a >> b >> s;
	if (s[a] != '-') { cout << "No" << endl; return 0; }
	
	rep(i, a) if (!('0' <= s[i] && s[i] <= '9')) { cout << "No" << endl; return 0; }
	rep(i, b) if (!('0' <= s[a+1+i] && s[a+1+i] <= '9')) { cout << "No" << endl; return 0; }
	cout << "Yes" << endl;
	return 0;
}
