#include <bits/stdc++.h>
using namespace std;
int main(void){
    // Your code here!
    int a,b;
    string s;
    cin>>a>>b>>s;
    for(int i=0; i<s.size(); i++){
            if(s[a]!='-'){
                    cout<<"No"
                    return 0;
            }
            else if(s[i]=='-'){
                    cout<<"No"
                    return 0;
            }
    }
    cout<<Yes
}