#include<stdio.h>
int main()
{
    int i,a,b,flag;
    while(scanf("%d %d",&a,&b)!=EOF)
    {
        char str[a+b+1],c;
        flag=1;
        c=getchar();
        scanf("%[0-9-]s",str);
        for(i=0;str[i]!='\0';i++)
        {
            if(i==a)
            continue;
            if(str[a]=='-'&&str[i]!='-')
                flag=0;
        }
        if(flag==0)
            printf("Yes\n");
        else
            printf("No\n");

    return 0;
}