import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int A = Integer.parseInt(sc.next());
		int B = Integer.parseInt(sc.next());
		String S = sc.next();
		sc.close();
		
		boolean check = true;
		for(int i = 0; i < S.length(); i++) {
			if(i == A) {
				if(S.charAt(i) == '-') {
					continue;
				}else {
					check = false;
					break;
				}
			}else {
				if(S.substring(i, i + 1).matches("[0-9]")) {
					continue;
				}else {
					check = false;
					break;
				}
			}
		}
		System.out.println(check ? "Yes" : "No");
	}

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

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int A = Integer.parseInt(sc.next());
		int B = Integer.parseInt(sc.next());
		String S = sc.next();
		sc.close();
		
		boolean check = true;
		for(int i = 0; i < S.length(); i++) {
			if(i == A) {
				if(S.charAt(i) == '-') {
					continue;
				}else {
					check = false;
					break;
				}
			}else {
				if(S.substring(i, i + 1).matches("[0-9]")) {
					continue;
				}else {
					check = false;
					break;
				}
			}
		}
		System.out.println(check ? "Yes" : "No");
	}

} Main public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int A = Integer.parseInt(sc.next());
		int B = Integer.parseInt(sc.next());
		String S = sc.next();
		sc.close();
		
		boolean check = true;
		for(int i = 0; i < S.length(); i++) {
			if(i == A) {
				if(S.charAt(i) == '-') {
					continue;
				}else {
					check = false;
					break;
				}
			}else {
				if(S.substring(i, i + 1).matches("[0-9]")) {
					continue;
				}else {
					check = false;
					break;
				}
			}
		}
		System.out.println(check ? "Yes" : "No");
	} main {
		Scanner sc = new Scanner(System.in);
		int A = Integer.parseInt(sc.next());
		int B = Integer.parseInt(sc.next());
		String S = sc.next();
		sc.close();
		
		boolean check = true;
		for(int i = 0; i < S.length(); i++) {
			if(i == A) {
				if(S.charAt(i) == '-') {
					continue;
				}else {
					check = false;
					break;
				}
			}else {
				if(S.substring(i, i + 1).matches("[0-9]")) {
					continue;
				}else {
					check = false;
					break;
				}
			}
		}
		System.out.println(check ? "Yes" : "No");
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int A = Integer.parseInt(sc.next()); A Integer.parseInt(sc.next()) Integer.parseInt Integer sc.next() sc.next sc int B = Integer.parseInt(sc.next()); B Integer.parseInt(sc.next()) Integer.parseInt Integer sc.next() sc.next sc String S = sc.next(); S sc.next() sc.next sc sc.close() sc.close sc boolean check = true; check true for(int i = 0; i < S.length(); i++) {
			if(i == A) {
				if(S.charAt(i) == '-') {
					continue;
				}else {
					check = false;
					break;
				}
			}else {
				if(S.substring(i, i + 1).matches("[0-9]")) {
					continue;
				}else {
					check = false;
					break;
				}
			}
		} int i = 0; int i = 0; i 0 i < S.length() i S.length() S.length S i++ i++ i {
			if(i == A) {
				if(S.charAt(i) == '-') {
					continue;
				}else {
					check = false;
					break;
				}
			}else {
				if(S.substring(i, i + 1).matches("[0-9]")) {
					continue;
				}else {
					check = false;
					break;
				}
			}
		} {
			if(i == A) {
				if(S.charAt(i) == '-') {
					continue;
				}else {
					check = false;
					break;
				}
			}else {
				if(S.substring(i, i + 1).matches("[0-9]")) {
					continue;
				}else {
					check = false;
					break;
				}
			}
		} if(i == A) {
				if(S.charAt(i) == '-') {
					continue;
				}else {
					check = false;
					break;
				}
			}else {
				if(S.substring(i, i + 1).matches("[0-9]")) {
					continue;
				}else {
					check = false;
					break;
				}
			} i == A i A {
				if(S.charAt(i) == '-') {
					continue;
				}else {
					check = false;
					break;
				}
			} if(S.charAt(i) == '-') {
					continue;
				}else {
					check = false;
					break;
				} S.charAt(i) == '-' S.charAt(i) S.charAt S i '-' {
					continue;
				} continue; {
					check = false;
					break;
				} check = false check false break; {
				if(S.substring(i, i + 1).matches("[0-9]")) {
					continue;
				}else {
					check = false;
					break;
				}
			} if(S.substring(i, i + 1).matches("[0-9]")) {
					continue;
				}else {
					check = false;
					break;
				} S.substring(i, i + 1).matches("[0-9]") S.substring(i, i + 1).matches S.substring(i, i + 1) S.substring S i i + 1 i 1 "[0-9]" {
					continue;
				} continue; {
					check = false;
					break;
				} check = false check false break; System.out.println(check ? "Yes" : "No") System.out.println System.out System System.out check ? "Yes" : "No" check "Yes" "No" String[] args args public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int A = Integer.parseInt(sc.next());
		int B = Integer.parseInt(sc.next());
		String S = sc.next();
		sc.close();
		
		boolean check = true;
		for(int i = 0; i < S.length(); i++) {
			if(i == A) {
				if(S.charAt(i) == '-') {
					continue;
				}else {
					check = false;
					break;
				}
			}else {
				if(S.substring(i, i + 1).matches("[0-9]")) {
					continue;
				}else {
					check = false;
					break;
				}
			}
		}
		System.out.println(check ? "Yes" : "No");
	}

} public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int A = Integer.parseInt(sc.next());
		int B = Integer.parseInt(sc.next());
		String S = sc.next();
		sc.close();
		
		boolean check = true;
		for(int i = 0; i < S.length(); i++) {
			if(i == A) {
				if(S.charAt(i) == '-') {
					continue;
				}else {
					check = false;
					break;
				}
			}else {
				if(S.substring(i, i + 1).matches("[0-9]")) {
					continue;
				}else {
					check = false;
					break;
				}
			}
		}
		System.out.println(check ? "Yes" : "No");
	}

} Main
import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int A = Integer.parseInt(sc.next());
		int B = Integer.parseInt(sc.next());
		String S = sc.next();
		sc.close();
		
		boolean check = true;
		for(int i = 0; i < S.length(); i++) {
			if(i == A) {
				if(S.charAt(i) == '-') {
					continue;
				}else {
					check = false;
					break;
				}
			}else {
				if(S.substring(i, i + 1).matches("[0-9]")) {
					continue;
				}else {
					check = false;
					break;
				}
			}
		}
		System.out.println(check ? "Yes" : "No");
	}

}
