#include <bits/stdc++.h>
using namespace std;
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
#define rep2(i, s, n) for (int i = (s); i < (int)(n); i++)
typedef long long ll;

int main() {
    int A, B;
    cin >> A >> B;
    string S;
    cin >> S;
    bool frag = true;
    for (int i = 0; i <= A+B; i++) {
        if (i != A && S[i] == '-'){
            cout << "No" << endl;
            frag = false;
            break;
        }
        if (i == ! && S[i] != '-'){
            cout << "No" << endl;
            frag = false;
            break;
        }
    }
    if (frag){
        cout << "Yes" << endl;
    }

}
