#include <algorithm>
#include <cstdio>
#include <functional>
#include <iostream>
#include <cfloat>
#include <climits>
#include <cstdlib>
#include <cstring>
#include <cmath>
#include <map>
#include <queue>
#include <set>
#include <sstream>
#include <stack>
#include <string>
#include <time.h>
#include <vector>
//#include <random>
//#include <unordered_set>
#include <complex>
using namespace std;
int main()
{
    int a,b,i;
    bool good=true;
    string s;
    cin>>a>>b>>s;
    if((s.size()!=(a+b+1))or(s[a]!='-')) good=false;
    for(i=0;i<s.size();i++) if(i!=a) if((s[i]!='1')or(s[i]!='2')or(s[i]!='3')or(s[i]!='4')or(s[i]!='5')or(s[i]!='6')or(s[i]!='7')or(s[i]!='8')or(s[i]!='9')or(s[i]!='0'))
                                     else good=false; 
    if(good==true) cout<<"Yes";
    else cout<<"No";
    system ("pause"); 
    return 0;
}