import java.util.*;
public class Main {
	public static void main(String args[]) {
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();
		String s = sc.next();
		boolean flag = true;
		for(int i=0 ; i<a+b ; i++) {
			if(i == a) {
				flag &= s.charAt(i) == '-';
			}else {
				flag &= Character.isDigit(s.charAt(i));
			}
		}
		System.out.println(flag ? "Yes":"No");
		
	}
} import java.util.*; util.* java public class Main {
	public static void main(String args[]) {
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();
		String s = sc.next();
		boolean flag = true;
		for(int i=0 ; i<a+b ; i++) {
			if(i == a) {
				flag &= s.charAt(i) == '-';
			}else {
				flag &= Character.isDigit(s.charAt(i));
			}
		}
		System.out.println(flag ? "Yes":"No");
		
	}
} Main public static void main(String args[]) {
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();
		String s = sc.next();
		boolean flag = true;
		for(int i=0 ; i<a+b ; i++) {
			if(i == a) {
				flag &= s.charAt(i) == '-';
			}else {
				flag &= Character.isDigit(s.charAt(i));
			}
		}
		System.out.println(flag ? "Yes":"No");
		
	} main {
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();
		String s = sc.next();
		boolean flag = true;
		for(int i=0 ; i<a+b ; i++) {
			if(i == a) {
				flag &= s.charAt(i) == '-';
			}else {
				flag &= Character.isDigit(s.charAt(i));
			}
		}
		System.out.println(flag ? "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 boolean flag = true; flag true for(int i=0 ; i<a+b ; i++) {
			if(i == a) {
				flag &= s.charAt(i) == '-';
			}else {
				flag &= Character.isDigit(s.charAt(i));
			}
		} int i=0 ; int i=0 ; i 0 i<a+b i a+b a b i++ i++ i {
			if(i == a) {
				flag &= s.charAt(i) == '-';
			}else {
				flag &= Character.isDigit(s.charAt(i));
			}
		} {
			if(i == a) {
				flag &= s.charAt(i) == '-';
			}else {
				flag &= Character.isDigit(s.charAt(i));
			}
		} if(i == a) {
				flag &= s.charAt(i) == '-';
			}else {
				flag &= Character.isDigit(s.charAt(i));
			} i == a i a {
				flag &= s.charAt(i) == '-';
			} flag &= s.charAt(i) == '-' flag s.charAt(i) == '-' s.charAt(i) s.charAt s i '-' {
				flag &= Character.isDigit(s.charAt(i));
			} flag &= Character.isDigit(s.charAt(i)) flag Character.isDigit(s.charAt(i)) Character.isDigit Character s.charAt(i) s.charAt s i System.out.println(flag ? "Yes":"No") System.out.println System.out System System.out flag ? "Yes":"No" flag "Yes" "No" String args[] args public class Main {
	public static void main(String args[]) {
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();
		String s = sc.next();
		boolean flag = true;
		for(int i=0 ; i<a+b ; i++) {
			if(i == a) {
				flag &= s.charAt(i) == '-';
			}else {
				flag &= Character.isDigit(s.charAt(i));
			}
		}
		System.out.println(flag ? "Yes":"No");
		
	}
} public class Main {
	public static void main(String args[]) {
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();
		String s = sc.next();
		boolean flag = true;
		for(int i=0 ; i<a+b ; i++) {
			if(i == a) {
				flag &= s.charAt(i) == '-';
			}else {
				flag &= Character.isDigit(s.charAt(i));
			}
		}
		System.out.println(flag ? "Yes":"No");
		
	}
} Main
import java.util.*;
public class Main {
	public static void main(String args[]) {
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();
		String s = sc.next();
		boolean flag = true;
		for(int i=0 ; i<a+b ; i++) {
			if(i == a) {
				flag &= s.charAt(i) == '-';
			}else {
				flag &= Character.isDigit(s.charAt(i));
			}
		}
		System.out.println(flag ? "Yes":"No");
		
	}
}
