#include <bits/stdc++.h>
using namespace std;
#define int long long int
int32_t main(){
	int a,b;string s;cin>>a>>b>>s;
	if(count(s.begin(),s.end(),'-')==1 && s[a]=='-') cout<<"Yes";
	else cout<<"No"; 
}
