#include <bits/stdc++.h>
#define ll long long
void no(){cout<<"No"<<endl;exit(0);}
void yes(){cout<<"Yes"<<endl;exit(0);}
using namespace std;
int main()
{
    int a,b;
    string s;
    cin>>a>>b;
    cin>>s;
    bool flag=true;
    for(int i=0;i<a+b+1;i++){
        if(i!=a){
        if(s[i]=='-')
        flag=false;
        }
    }
    if(s[a]!='-') flag=false;
    if(flag==true) yes();
    else no();
}