import java.util.*;
public class Main{

	public static void main(String[] args) {
		// TODO Auto-generated method stub
		Scanner sc = new Scanner(System.in);
		
		int A = sc.nextInt(), B = sc.nextInt();
		
		String s = sc.next();
		
		for(int i = 0; i<A; i++) {
			if(s.charAt(i) - '0' < 0 && s.charAt(i) > 9) {
				System.out.println("No");
				System.exit(0);
			}
		}
		
		if(s.charAt(A) != '-') { System.out.println("No"); System.exit(0); }
		
		for(int i = A+1; i<=A+B; i++) {
			if(s.charAt(i) - '0' < 0 && s.charAt(i) > 9) {
				System.out.println("No");
				System.exit(0);
			}		
		}
		
		System.out.println("Yes");
	}

} import java.util.*; util.* java public class Main{

	public static void main(String[] args) {
		// TODO Auto-generated method stub
		Scanner sc = new Scanner(System.in);
		
		int A = sc.nextInt(), B = sc.nextInt();
		
		String s = sc.next();
		
		for(int i = 0; i<A; i++) {
			if(s.charAt(i) - '0' < 0 && s.charAt(i) > 9) {
				System.out.println("No");
				System.exit(0);
			}
		}
		
		if(s.charAt(A) != '-') { System.out.println("No"); System.exit(0); }
		
		for(int i = A+1; i<=A+B; i++) {
			if(s.charAt(i) - '0' < 0 && s.charAt(i) > 9) {
				System.out.println("No");
				System.exit(0);
			}		
		}
		
		System.out.println("Yes");
	}

} Main public static void main(String[] args) {
		// TODO Auto-generated method stub
		Scanner sc = new Scanner(System.in);
		
		int A = sc.nextInt(), B = sc.nextInt();
		
		String s = sc.next();
		
		for(int i = 0; i<A; i++) {
			if(s.charAt(i) - '0' < 0 && s.charAt(i) > 9) {
				System.out.println("No");
				System.exit(0);
			}
		}
		
		if(s.charAt(A) != '-') { System.out.println("No"); System.exit(0); }
		
		for(int i = A+1; i<=A+B; i++) {
			if(s.charAt(i) - '0' < 0 && s.charAt(i) > 9) {
				System.out.println("No");
				System.exit(0);
			}		
		}
		
		System.out.println("Yes");
	} main {
		// TODO Auto-generated method stub
		Scanner sc = new Scanner(System.in);
		
		int A = sc.nextInt(), B = sc.nextInt();
		
		String s = sc.next();
		
		for(int i = 0; i<A; i++) {
			if(s.charAt(i) - '0' < 0 && s.charAt(i) > 9) {
				System.out.println("No");
				System.exit(0);
			}
		}
		
		if(s.charAt(A) != '-') { System.out.println("No"); System.exit(0); }
		
		for(int i = A+1; i<=A+B; i++) {
			if(s.charAt(i) - '0' < 0 && s.charAt(i) > 9) {
				System.out.println("No");
				System.exit(0);
			}		
		}
		
		System.out.println("Yes");
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int A = sc.nextInt() A sc.nextInt() sc.nextInt sc B = sc.nextInt(); B sc.nextInt() sc.nextInt sc String s = sc.next(); s sc.next() sc.next sc for(int i = 0; i<A; i++) {
			if(s.charAt(i) - '0' < 0 && s.charAt(i) > 9) {
				System.out.println("No");
				System.exit(0);
			}
		} int i = 0; int i = 0; i 0 i<A i A i++ i++ i {
			if(s.charAt(i) - '0' < 0 && s.charAt(i) > 9) {
				System.out.println("No");
				System.exit(0);
			}
		} {
			if(s.charAt(i) - '0' < 0 && s.charAt(i) > 9) {
				System.out.println("No");
				System.exit(0);
			}
		} if(s.charAt(i) - '0' < 0 && s.charAt(i) > 9) {
				System.out.println("No");
				System.exit(0);
			} s.charAt(i) - '0' < 0 && s.charAt(i) > 9 s.charAt(i) - '0' < 0 s.charAt(i) - '0' s.charAt(i) s.charAt s i '0' 0 s.charAt(i) > 9 s.charAt(i) s.charAt s i 9 {
				System.out.println("No");
				System.exit(0);
			} System.out.println("No") System.out.println System.out System System.out "No" System.exit(0) System.exit System 0 if(s.charAt(A) != '-') { System.out.println("No"); System.exit(0); } s.charAt(A) != '-' s.charAt(A) s.charAt s A '-' { System.out.println("No"); System.exit(0); } System.out.println("No") System.out.println System.out System System.out "No" System.exit(0) System.exit System 0 for(int i = A+1; i<=A+B; i++) {
			if(s.charAt(i) - '0' < 0 && s.charAt(i) > 9) {
				System.out.println("No");
				System.exit(0);
			}		
		} int i = A+1; int i = A+1; i A+1 A 1 i<=A+B i A+B A B i++ i++ i {
			if(s.charAt(i) - '0' < 0 && s.charAt(i) > 9) {
				System.out.println("No");
				System.exit(0);
			}		
		} {
			if(s.charAt(i) - '0' < 0 && s.charAt(i) > 9) {
				System.out.println("No");
				System.exit(0);
			}		
		} if(s.charAt(i) - '0' < 0 && s.charAt(i) > 9) {
				System.out.println("No");
				System.exit(0);
			} s.charAt(i) - '0' < 0 && s.charAt(i) > 9 s.charAt(i) - '0' < 0 s.charAt(i) - '0' s.charAt(i) s.charAt s i '0' 0 s.charAt(i) > 9 s.charAt(i) s.charAt s i 9 {
				System.out.println("No");
				System.exit(0);
			} System.out.println("No") System.out.println System.out System System.out "No" System.exit(0) System.exit System 0 System.out.println("Yes") System.out.println System.out System System.out "Yes" String[] args args public class Main{

	public static void main(String[] args) {
		// TODO Auto-generated method stub
		Scanner sc = new Scanner(System.in);
		
		int A = sc.nextInt(), B = sc.nextInt();
		
		String s = sc.next();
		
		for(int i = 0; i<A; i++) {
			if(s.charAt(i) - '0' < 0 && s.charAt(i) > 9) {
				System.out.println("No");
				System.exit(0);
			}
		}
		
		if(s.charAt(A) != '-') { System.out.println("No"); System.exit(0); }
		
		for(int i = A+1; i<=A+B; i++) {
			if(s.charAt(i) - '0' < 0 && s.charAt(i) > 9) {
				System.out.println("No");
				System.exit(0);
			}		
		}
		
		System.out.println("Yes");
	}

} public class Main{

	public static void main(String[] args) {
		// TODO Auto-generated method stub
		Scanner sc = new Scanner(System.in);
		
		int A = sc.nextInt(), B = sc.nextInt();
		
		String s = sc.next();
		
		for(int i = 0; i<A; i++) {
			if(s.charAt(i) - '0' < 0 && s.charAt(i) > 9) {
				System.out.println("No");
				System.exit(0);
			}
		}
		
		if(s.charAt(A) != '-') { System.out.println("No"); System.exit(0); }
		
		for(int i = A+1; i<=A+B; i++) {
			if(s.charAt(i) - '0' < 0 && s.charAt(i) > 9) {
				System.out.println("No");
				System.exit(0);
			}		
		}
		
		System.out.println("Yes");
	}

} Main
import java.util.*;
public class Main{

	public static void main(String[] args) {
		// TODO Auto-generated method stub
		Scanner sc = new Scanner(System.in);
		
		int A = sc.nextInt(), B = sc.nextInt();
		
		String s = sc.next();
		
		for(int i = 0; i<A; i++) {
			if(s.charAt(i) - '0' < 0 && s.charAt(i) > 9) {
				System.out.println("No");
				System.exit(0);
			}
		}
		
		if(s.charAt(A) != '-') { System.out.println("No"); System.exit(0); }
		
		for(int i = A+1; i<=A+B; i++) {
			if(s.charAt(i) - '0' < 0 && s.charAt(i) > 9) {
				System.out.println("No");
				System.exit(0);
			}		
		}
		
		System.out.println("Yes");
	}

}
