A, B= [int(input() )for _ in range(2)]
S = str(input())

try:
    if (type(int(S[:A]))== int):
        if S[A]=="-": 
            if type(int(S[A+1:]))==int:
                print('Yes')
    else:
        print('No')
except:
    print("No")