#include<iostream>
#include<cstring>
using namespace std;
string s;
int main(){
    int n,m;
    cin>>n>>m>>s;
    int i;
    for(i=0;i<n;i++)
        if(s[i]>='9'||s[i]<='0'){
            cout<<"No"<<endl;
            return 0;
        }
    if(a[i]!='-'){
        cout<<"No"<<endl;
        return 0;
    }
    for(i=n+1;i<n+m+1;i++)
        if(s[i]>='9'||s[i]<='0'){
            cout<<"No"<<endl;
            return 0;
        }
    cout<<"Yes"<<endl;
}