a, b = map(int, raw_input().split())
s = raw_input()
flag = False
for i in range(0, a+b+1):
	if s[i] == '-':
		if i == a:
			flag = True
		else:
			flag = False
			break
if flag:
	print 'Yes'
else:
	print 'No'