#include<iostream>
using namespace std;
int a,b;
int main(){
    string s;
    cin>>a>>b>>s;
    bool ok=1;
    int j=0;
    for(int i=0;i<a+b+1;i++){
        if(s[i]=='-')j++;
    }
    if(j!=1)ok=0;
    if(s[a]!='-')ok=0;
    cout<<(ok?"Yes":"No")<<endl;
}