import java.util.*;
public class Main{
	static boolean PostNumCheck(String s, int p, int q){
		if(s.charAt(p)!='-')return false;
		for(int i=0; i<p; i++){
			if(s.charAt(i)=='-')return false;
		}
		for(int i=p+1; i<p+q+1; i++){
			if(s.charAt(i)=='-')return false;
		}
		return true;
	}

	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();
		String S = sc.next();
		System.out.println(PostNumCheck(S, a, b)==true ? "Yes" : "No");
	}
} import java.util.*; util.* java public class Main{
	static boolean PostNumCheck(String s, int p, int q){
		if(s.charAt(p)!='-')return false;
		for(int i=0; i<p; i++){
			if(s.charAt(i)=='-')return false;
		}
		for(int i=p+1; i<p+q+1; i++){
			if(s.charAt(i)=='-')return false;
		}
		return true;
	}

	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();
		String S = sc.next();
		System.out.println(PostNumCheck(S, a, b)==true ? "Yes" : "No");
	}
} Main static boolean PostNumCheck(String s, int p, int q){
		if(s.charAt(p)!='-')return false;
		for(int i=0; i<p; i++){
			if(s.charAt(i)=='-')return false;
		}
		for(int i=p+1; i<p+q+1; i++){
			if(s.charAt(i)=='-')return false;
		}
		return true;
	} PostNumCheck {
		if(s.charAt(p)!='-')return false;
		for(int i=0; i<p; i++){
			if(s.charAt(i)=='-')return false;
		}
		for(int i=p+1; i<p+q+1; i++){
			if(s.charAt(i)=='-')return false;
		}
		return true;
	} if(s.charAt(p)!='-')return false; s.charAt(p)!='-' s.charAt(p) s.charAt s p '-' return false; false for(int i=0; i<p; i++){
			if(s.charAt(i)=='-')return false;
		} int i=0; int i=0; i 0 i<p i p i++ i++ i {
			if(s.charAt(i)=='-')return false;
		} {
			if(s.charAt(i)=='-')return false;
		} if(s.charAt(i)=='-')return false; s.charAt(i)=='-' s.charAt(i) s.charAt s i '-' return false; false for(int i=p+1; i<p+q+1; i++){
			if(s.charAt(i)=='-')return false;
		} int i=p+1; int i=p+1; i p+1 p 1 i<p+q+1 i p+q+1 p+q+1 p q 1 i++ i++ i {
			if(s.charAt(i)=='-')return false;
		} {
			if(s.charAt(i)=='-')return false;
		} if(s.charAt(i)=='-')return false; s.charAt(i)=='-' s.charAt(i) s.charAt s i '-' return false; false return true; true String s s int p p int q q public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();
		String S = sc.next();
		System.out.println(PostNumCheck(S, a, b)==true ? "Yes" : "No");
	} main {
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();
		String S = sc.next();
		System.out.println(PostNumCheck(S, a, b)==true ? "Yes" : "No");
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int a = sc.nextInt(); a sc.nextInt() sc.nextInt sc int b = sc.nextInt(); b sc.nextInt() sc.nextInt sc String S = sc.next(); S sc.next() sc.next sc System.out.println(PostNumCheck(S, a, b)==true ? "Yes" : "No") System.out.println System.out System System.out PostNumCheck(S, a, b)==true ? "Yes" : "No" PostNumCheck(S, a, b)==true PostNumCheck(S, a, b) PostNumCheck S a b true "Yes" "No" String[] args args public class Main{
	static boolean PostNumCheck(String s, int p, int q){
		if(s.charAt(p)!='-')return false;
		for(int i=0; i<p; i++){
			if(s.charAt(i)=='-')return false;
		}
		for(int i=p+1; i<p+q+1; i++){
			if(s.charAt(i)=='-')return false;
		}
		return true;
	}

	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();
		String S = sc.next();
		System.out.println(PostNumCheck(S, a, b)==true ? "Yes" : "No");
	}
} public class Main{
	static boolean PostNumCheck(String s, int p, int q){
		if(s.charAt(p)!='-')return false;
		for(int i=0; i<p; i++){
			if(s.charAt(i)=='-')return false;
		}
		for(int i=p+1; i<p+q+1; i++){
			if(s.charAt(i)=='-')return false;
		}
		return true;
	}

	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();
		String S = sc.next();
		System.out.println(PostNumCheck(S, a, b)==true ? "Yes" : "No");
	}
} Main
import java.util.*;
public class Main{
	static boolean PostNumCheck(String s, int p, int q){
		if(s.charAt(p)!='-')return false;
		for(int i=0; i<p; i++){
			if(s.charAt(i)=='-')return false;
		}
		for(int i=p+1; i<p+q+1; i++){
			if(s.charAt(i)=='-')return false;
		}
		return true;
	}

	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();
		String S = sc.next();
		System.out.println(PostNumCheck(S, a, b)==true ? "Yes" : "No");
	}
}