import java.util.*;

public class Main {

    public static String isGood(int A, int B, String S) {
        if (S.length() != A + B + 1) {
            return "No";
        } else {
            for (int i = 0; i < A + B + 1; i++) {
                if (i == A) {
                    if (S.charAt(i) != '-') {
                        return "No";
                    }
                } else {
                    if (!('0' <= S.charAt(i) && S.charAt(i) <= '9')) {
                        return "No";
                    }
                }
            }
            return "Yes";
        }
    }

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int A = sc.nextInt();
        int B = sc.nextInt();
        String S = sc.next();
        System.out.println(isGood(A, B, S));
    }

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

    public static String isGood(int A, int B, String S) {
        if (S.length() != A + B + 1) {
            return "No";
        } else {
            for (int i = 0; i < A + B + 1; i++) {
                if (i == A) {
                    if (S.charAt(i) != '-') {
                        return "No";
                    }
                } else {
                    if (!('0' <= S.charAt(i) && S.charAt(i) <= '9')) {
                        return "No";
                    }
                }
            }
            return "Yes";
        }
    }

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int A = sc.nextInt();
        int B = sc.nextInt();
        String S = sc.next();
        System.out.println(isGood(A, B, S));
    }

} Main public static String isGood(int A, int B, String S) {
        if (S.length() != A + B + 1) {
            return "No";
        } else {
            for (int i = 0; i < A + B + 1; i++) {
                if (i == A) {
                    if (S.charAt(i) != '-') {
                        return "No";
                    }
                } else {
                    if (!('0' <= S.charAt(i) && S.charAt(i) <= '9')) {
                        return "No";
                    }
                }
            }
            return "Yes";
        }
    } isGood {
        if (S.length() != A + B + 1) {
            return "No";
        } else {
            for (int i = 0; i < A + B + 1; i++) {
                if (i == A) {
                    if (S.charAt(i) != '-') {
                        return "No";
                    }
                } else {
                    if (!('0' <= S.charAt(i) && S.charAt(i) <= '9')) {
                        return "No";
                    }
                }
            }
            return "Yes";
        }
    } if (S.length() != A + B + 1) {
            return "No";
        } else {
            for (int i = 0; i < A + B + 1; i++) {
                if (i == A) {
                    if (S.charAt(i) != '-') {
                        return "No";
                    }
                } else {
                    if (!('0' <= S.charAt(i) && S.charAt(i) <= '9')) {
                        return "No";
                    }
                }
            }
            return "Yes";
        } S.length() != A + B + 1 S.length() S.length S A + B + 1 A + B + 1 A B 1 {
            return "No";
        } return "No"; "No" {
            for (int i = 0; i < A + B + 1; i++) {
                if (i == A) {
                    if (S.charAt(i) != '-') {
                        return "No";
                    }
                } else {
                    if (!('0' <= S.charAt(i) && S.charAt(i) <= '9')) {
                        return "No";
                    }
                }
            }
            return "Yes";
        } for (int i = 0; i < A + B + 1; i++) {
                if (i == A) {
                    if (S.charAt(i) != '-') {
                        return "No";
                    }
                } else {
                    if (!('0' <= S.charAt(i) && S.charAt(i) <= '9')) {
                        return "No";
                    }
                }
            } int i = 0; int i = 0; i 0 i < A + B + 1 i A + B + 1 A + B + 1 A B 1 i++ i++ i {
                if (i == A) {
                    if (S.charAt(i) != '-') {
                        return "No";
                    }
                } else {
                    if (!('0' <= S.charAt(i) && S.charAt(i) <= '9')) {
                        return "No";
                    }
                }
            } {
                if (i == A) {
                    if (S.charAt(i) != '-') {
                        return "No";
                    }
                } else {
                    if (!('0' <= S.charAt(i) && S.charAt(i) <= '9')) {
                        return "No";
                    }
                }
            } if (i == A) {
                    if (S.charAt(i) != '-') {
                        return "No";
                    }
                } else {
                    if (!('0' <= S.charAt(i) && S.charAt(i) <= '9')) {
                        return "No";
                    }
                } i == A i A {
                    if (S.charAt(i) != '-') {
                        return "No";
                    }
                } if (S.charAt(i) != '-') {
                        return "No";
                    } S.charAt(i) != '-' S.charAt(i) S.charAt S i '-' {
                        return "No";
                    } return "No"; "No" {
                    if (!('0' <= S.charAt(i) && S.charAt(i) <= '9')) {
                        return "No";
                    }
                } if (!('0' <= S.charAt(i) && S.charAt(i) <= '9')) {
                        return "No";
                    } !('0' <= S.charAt(i) && S.charAt(i) <= '9') ('0' <= S.charAt(i) && S.charAt(i) <= '9') '0' <= S.charAt(i) '0' S.charAt(i) S.charAt S i S.charAt(i) <= '9' S.charAt(i) S.charAt S i '9' {
                        return "No";
                    } return "No"; "No" return "Yes"; "Yes" int A A int B B String S S public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int A = sc.nextInt();
        int B = sc.nextInt();
        String S = sc.next();
        System.out.println(isGood(A, B, S));
    } main {
        Scanner sc = new Scanner(System.in);
        int A = sc.nextInt();
        int B = sc.nextInt();
        String S = sc.next();
        System.out.println(isGood(A, B, S));
    } 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 System.out.println(isGood(A, B, S)) System.out.println System.out System System.out isGood(A, B, S) isGood A B S String[] args args public class Main {

    public static String isGood(int A, int B, String S) {
        if (S.length() != A + B + 1) {
            return "No";
        } else {
            for (int i = 0; i < A + B + 1; i++) {
                if (i == A) {
                    if (S.charAt(i) != '-') {
                        return "No";
                    }
                } else {
                    if (!('0' <= S.charAt(i) && S.charAt(i) <= '9')) {
                        return "No";
                    }
                }
            }
            return "Yes";
        }
    }

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int A = sc.nextInt();
        int B = sc.nextInt();
        String S = sc.next();
        System.out.println(isGood(A, B, S));
    }

} public class Main {

    public static String isGood(int A, int B, String S) {
        if (S.length() != A + B + 1) {
            return "No";
        } else {
            for (int i = 0; i < A + B + 1; i++) {
                if (i == A) {
                    if (S.charAt(i) != '-') {
                        return "No";
                    }
                } else {
                    if (!('0' <= S.charAt(i) && S.charAt(i) <= '9')) {
                        return "No";
                    }
                }
            }
            return "Yes";
        }
    }

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int A = sc.nextInt();
        int B = sc.nextInt();
        String S = sc.next();
        System.out.println(isGood(A, B, S));
    }

} Main
import java.util.*;

public class Main {

    public static String isGood(int A, int B, String S) {
        if (S.length() != A + B + 1) {
            return "No";
        } else {
            for (int i = 0; i < A + B + 1; i++) {
                if (i == A) {
                    if (S.charAt(i) != '-') {
                        return "No";
                    }
                } else {
                    if (!('0' <= S.charAt(i) && S.charAt(i) <= '9')) {
                        return "No";
                    }
                }
            }
            return "Yes";
        }
    }

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int A = sc.nextInt();
        int B = sc.nextInt();
        String S = sc.next();
        System.out.println(isGood(A, B, S));
    }

}
