#include<iostream>
#include<algorithm>
#include<math.h>
using namespace std;

int main(){
    int A, B;
    char S[20];
    cin >> A >> B >> S;
    for(int i = 0; i < A; i++) if(!('0' <= S[i] && S[i] <= '9')){
        cout << "No" << endl;
        retun 0;
    }
    if(S[A] != '-'){
        cout << "No" << endl;
        return 0;
    }
    for(int i = A + 1; i < A + B + 1; i++) if(!('0' <= S[i] && S[i] <= '9')){
        cout << "No" << endl;
        retunr 0;
    }
    cout << "Yes" << endl;
	
	return 0;
}