#include<cstdio>
char s[20];
int main(){
    int a,b,i,ok=1;
    scanf("%d%d",&a,&b);
    scanf("%s",s);
    for(i=0;i<a;i++)if(s[i]<'0'||s[i]>'9')ok=0;
    if(s[a]!='-')ok=0;
    for(i=a+1;i<=a+b;i++)if(s[i]<'0'||s[i]>'9')ok=0;
    printf("%s\n",ok?"Yes":"No");
    return 0;
}