import java.util.Scanner;

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();
		String ans = "No";

		try {
			Integer.parseInt(s.substring(0, a));

			Integer.parseInt(s.substring(a + 1));
			if (s.length() == a + b + 1) {
				if (s.charAt(a) == '-') {
					ans = "Yes";
				}
			}
		} catch (NumberFormatException e) {
		}
		System.out.println(ans);

	}
} import java.util.Scanner; Scanner 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();
		String ans = "No";

		try {
			Integer.parseInt(s.substring(0, a));

			Integer.parseInt(s.substring(a + 1));
			if (s.length() == a + b + 1) {
				if (s.charAt(a) == '-') {
					ans = "Yes";
				}
			}
		} catch (NumberFormatException e) {
		}
		System.out.println(ans);

	}
} 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();
		String ans = "No";

		try {
			Integer.parseInt(s.substring(0, a));

			Integer.parseInt(s.substring(a + 1));
			if (s.length() == a + b + 1) {
				if (s.charAt(a) == '-') {
					ans = "Yes";
				}
			}
		} catch (NumberFormatException e) {
		}
		System.out.println(ans);

	} main {
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();
		String s = sc.next();
		String ans = "No";

		try {
			Integer.parseInt(s.substring(0, a));

			Integer.parseInt(s.substring(a + 1));
			if (s.length() == a + b + 1) {
				if (s.charAt(a) == '-') {
					ans = "Yes";
				}
			}
		} catch (NumberFormatException e) {
		}
		System.out.println(ans);

	} 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 String ans = "No"; ans "No" try {
			Integer.parseInt(s.substring(0, a));

			Integer.parseInt(s.substring(a + 1));
			if (s.length() == a + b + 1) {
				if (s.charAt(a) == '-') {
					ans = "Yes";
				}
			}
		} catch (NumberFormatException e) {
		} catch (NumberFormatException e) {
		} NumberFormatException e {
		} {
			Integer.parseInt(s.substring(0, a));

			Integer.parseInt(s.substring(a + 1));
			if (s.length() == a + b + 1) {
				if (s.charAt(a) == '-') {
					ans = "Yes";
				}
			}
		} Integer.parseInt(s.substring(0, a)) Integer.parseInt Integer s.substring(0, a) s.substring s 0 a Integer.parseInt(s.substring(a + 1)) Integer.parseInt Integer s.substring(a + 1) s.substring s a + 1 a 1 if (s.length() == a + b + 1) {
				if (s.charAt(a) == '-') {
					ans = "Yes";
				}
			} s.length() == a + b + 1 s.length() s.length s a + b + 1 a + b + 1 a b 1 {
				if (s.charAt(a) == '-') {
					ans = "Yes";
				}
			} if (s.charAt(a) == '-') {
					ans = "Yes";
				} s.charAt(a) == '-' s.charAt(a) s.charAt s a '-' {
					ans = "Yes";
				} ans = "Yes" ans "Yes" System.out.println(ans) System.out.println System.out System System.out ans 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();
		String ans = "No";

		try {
			Integer.parseInt(s.substring(0, a));

			Integer.parseInt(s.substring(a + 1));
			if (s.length() == a + b + 1) {
				if (s.charAt(a) == '-') {
					ans = "Yes";
				}
			}
		} catch (NumberFormatException e) {
		}
		System.out.println(ans);

	}
} 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();
		String ans = "No";

		try {
			Integer.parseInt(s.substring(0, a));

			Integer.parseInt(s.substring(a + 1));
			if (s.length() == a + b + 1) {
				if (s.charAt(a) == '-') {
					ans = "Yes";
				}
			}
		} catch (NumberFormatException e) {
		}
		System.out.println(ans);

	}
} Main
import java.util.Scanner;

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();
		String ans = "No";

		try {
			Integer.parseInt(s.substring(0, a));

			Integer.parseInt(s.substring(a + 1));
			if (s.length() == a + b + 1) {
				if (s.charAt(a) == '-') {
					ans = "Yes";
				}
			}
		} catch (NumberFormatException e) {
		}
		System.out.println(ans);

	}
}