# --*-- encoding:utf-8 --*--

ab = list(map(int, input().split(" ")))
code = input()

notflag = False
for i in range(ab[0]):
	if( code[i] not in "123456789" ):
		notflag = True

if( code[ab[0]] != "-" ):
	notflag = True

for i in range(ab[0]+1, ab[1]):
	if( code[i] not in "123456789" ):
		notflag = True

if(notflag == False):
	print("Yes")
else:
	print("No")
