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();

		char[] c = s.toCharArray();

		boolean can = true;
		for (int i = 0; i < s.length(); i++) {
			if (i == a && c[i] != '-') {
				can = false;
			}
			if (i != a && c[i] == '-') {
				can = false;
			}
		}

		if (can) {
			System.out.println("Yes");
		} else {
			System.out.println("No");
		}

		sc.close();
	}

} 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();

		char[] c = s.toCharArray();

		boolean can = true;
		for (int i = 0; i < s.length(); i++) {
			if (i == a && c[i] != '-') {
				can = false;
			}
			if (i != a && c[i] == '-') {
				can = false;
			}
		}

		if (can) {
			System.out.println("Yes");
		} else {
			System.out.println("No");
		}

		sc.close();
	}

} 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();

		char[] c = s.toCharArray();

		boolean can = true;
		for (int i = 0; i < s.length(); i++) {
			if (i == a && c[i] != '-') {
				can = false;
			}
			if (i != a && c[i] == '-') {
				can = false;
			}
		}

		if (can) {
			System.out.println("Yes");
		} else {
			System.out.println("No");
		}

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

		char[] c = s.toCharArray();

		boolean can = true;
		for (int i = 0; i < s.length(); i++) {
			if (i == a && c[i] != '-') {
				can = false;
			}
			if (i != a && c[i] == '-') {
				can = false;
			}
		}

		if (can) {
			System.out.println("Yes");
		} else {
			System.out.println("No");
		}

		sc.close();
	} 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 char[] c = s.toCharArray(); c s.toCharArray() s.toCharArray s boolean can = true; can true for (int i = 0; i < s.length(); i++) {
			if (i == a && c[i] != '-') {
				can = false;
			}
			if (i != a && c[i] == '-') {
				can = false;
			}
		} int i = 0; int i = 0; i 0 i < s.length() i s.length() s.length s i++ i++ i {
			if (i == a && c[i] != '-') {
				can = false;
			}
			if (i != a && c[i] == '-') {
				can = false;
			}
		} {
			if (i == a && c[i] != '-') {
				can = false;
			}
			if (i != a && c[i] == '-') {
				can = false;
			}
		} if (i == a && c[i] != '-') {
				can = false;
			} i == a && c[i] != '-' i == a i a c[i] != '-' c[i] c i '-' {
				can = false;
			} can = false can false if (i != a && c[i] == '-') {
				can = false;
			} i != a && c[i] == '-' i != a i a c[i] == '-' c[i] c i '-' {
				can = false;
			} can = false can false if (can) {
			System.out.println("Yes");
		} else {
			System.out.println("No");
		} can {
			System.out.println("Yes");
		} System.out.println("Yes") System.out.println System.out System System.out "Yes" {
			System.out.println("No");
		} System.out.println("No") System.out.println System.out System System.out "No" sc.close() sc.close sc 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();

		char[] c = s.toCharArray();

		boolean can = true;
		for (int i = 0; i < s.length(); i++) {
			if (i == a && c[i] != '-') {
				can = false;
			}
			if (i != a && c[i] == '-') {
				can = false;
			}
		}

		if (can) {
			System.out.println("Yes");
		} else {
			System.out.println("No");
		}

		sc.close();
	}

} 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();

		char[] c = s.toCharArray();

		boolean can = true;
		for (int i = 0; i < s.length(); i++) {
			if (i == a && c[i] != '-') {
				can = false;
			}
			if (i != a && c[i] == '-') {
				can = false;
			}
		}

		if (can) {
			System.out.println("Yes");
		} else {
			System.out.println("No");
		}

		sc.close();
	}

} 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();

		char[] c = s.toCharArray();

		boolean can = true;
		for (int i = 0; i < s.length(); i++) {
			if (i == a && c[i] != '-') {
				can = false;
			}
			if (i != a && c[i] == '-') {
				can = false;
			}
		}

		if (can) {
			System.out.println("Yes");
		} else {
			System.out.println("No");
		}

		sc.close();
	}

}
