#include<bits/stdc++.h>
using namespace std;
int a,b,k;
string str;
int main()
{
    cin>>a>>b>>str;
    for(int i=0;i<=a+b;i++)
	{
        if(isdigit(str[i])) continue;
		else if(i != a) { k = 1; break; }
    }
    if(str[a]!='-') k = 1;
    if(k) cout<<"No\n";
    else cout<<"Yes\n";
    return 0;
}