def eval(A, B, S):
	if len(S) != A + B + 1:
		return False
	if S[A] != '-':
		return False
	for i in range(A):
		if not S[i].isdigit():
			return False
	for i in range(B):
		if not S[i + A + 1].isdigit():
			return False
	return True


A, B = map(int, raw_input().split())
S = raw_input()
if eval(A, B, S):
	print "Yes"
else:
	print "No"

