import java.util.Scanner;
import java.util.regex.Pattern;

public class Main {

    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int A = scanner.nextInt();
        int B = scanner.nextInt();
        String S = scanner.next();

        String Asub = S.substring(0, A);
        String Bsub = S.substring(A+1, A+B+1);

        /*
        System.out.println("Asub：" + Asub);
        System.out.println(isNum(Asub));
        System.out.println("Bsub：" + Bsub);
        System.out.println(isNum(Bsub));
        */

        String result = "No";
        //文字列が数字かつ、文字列のA+1番目がハイフン
        if (isNum(Asub) && isNum(Bsub) && S.substring(A, A+1).equals("-")) {
            result = "Yes";
        }
        System.out.println(result);
    }

    //文字列が数字か判定
    public static boolean isNum(String s) {
        return Pattern.compile("^-?[0-9]+$").matcher(s).find();
    }

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

    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int A = scanner.nextInt();
        int B = scanner.nextInt();
        String S = scanner.next();

        String Asub = S.substring(0, A);
        String Bsub = S.substring(A+1, A+B+1);

        /*
        System.out.println("Asub：" + Asub);
        System.out.println(isNum(Asub));
        System.out.println("Bsub：" + Bsub);
        System.out.println(isNum(Bsub));
        */

        String result = "No";
        //文字列が数字かつ、文字列のA+1番目がハイフン
        if (isNum(Asub) && isNum(Bsub) && S.substring(A, A+1).equals("-")) {
            result = "Yes";
        }
        System.out.println(result);
    }

    //文字列が数字か判定
    public static boolean isNum(String s) {
        return Pattern.compile("^-?[0-9]+$").matcher(s).find();
    }

} Main public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int A = scanner.nextInt();
        int B = scanner.nextInt();
        String S = scanner.next();

        String Asub = S.substring(0, A);
        String Bsub = S.substring(A+1, A+B+1);

        /*
        System.out.println("Asub：" + Asub);
        System.out.println(isNum(Asub));
        System.out.println("Bsub：" + Bsub);
        System.out.println(isNum(Bsub));
        */

        String result = "No";
        //文字列が数字かつ、文字列のA+1番目がハイフン
        if (isNum(Asub) && isNum(Bsub) && S.substring(A, A+1).equals("-")) {
            result = "Yes";
        }
        System.out.println(result);
    } main {
        Scanner scanner = new Scanner(System.in);
        int A = scanner.nextInt();
        int B = scanner.nextInt();
        String S = scanner.next();

        String Asub = S.substring(0, A);
        String Bsub = S.substring(A+1, A+B+1);

        /*
        System.out.println("Asub：" + Asub);
        System.out.println(isNum(Asub));
        System.out.println("Bsub：" + Bsub);
        System.out.println(isNum(Bsub));
        */

        String result = "No";
        //文字列が数字かつ、文字列のA+1番目がハイフン
        if (isNum(Asub) && isNum(Bsub) && S.substring(A, A+1).equals("-")) {
            result = "Yes";
        }
        System.out.println(result);
    } Scanner scanner = new Scanner(System.in); scanner new Scanner(System.in) int A = scanner.nextInt(); A scanner.nextInt() scanner.nextInt scanner int B = scanner.nextInt(); B scanner.nextInt() scanner.nextInt scanner String S = scanner.next(); S scanner.next() scanner.next scanner String Asub = S.substring(0, A); Asub S.substring(0, A) S.substring S 0 A String Bsub = S.substring(A+1, A+B+1); Bsub S.substring(A+1, A+B+1) S.substring S A+1 A 1 A+B+1 A+B+1 A B 1 String result = "No"; result "No" if (isNum(Asub) && isNum(Bsub) && S.substring(A, A+1).equals("-")) {
            result = "Yes";
        } isNum(Asub) && isNum(Bsub) && S.substring(A, A+1).equals("-") isNum(Asub) && isNum(Bsub) && S.substring(A, A+1).equals("-") isNum(Asub) isNum Asub isNum(Bsub) isNum Bsub S.substring(A, A+1).equals("-") S.substring(A, A+1).equals S.substring(A, A+1) S.substring S A A+1 A 1 "-" {
            result = "Yes";
        } result = "Yes" result "Yes" System.out.println(result) System.out.println System.out System System.out result String[] args args //文字列が数字か判定
    public static boolean isNum(String s) {
        return Pattern.compile("^-?[0-9]+$").matcher(s).find();
    } isNum {
        return Pattern.compile("^-?[0-9]+$").matcher(s).find();
    } return Pattern.compile("^-?[0-9]+$").matcher(s).find(); Pattern.compile("^-?[0-9]+$").matcher(s).find() Pattern.compile("^-?[0-9]+$").matcher(s).find Pattern.compile("^-?[0-9]+$").matcher(s) Pattern.compile("^-?[0-9]+$").matcher Pattern.compile("^-?[0-9]+$") Pattern.compile Pattern "^-?[0-9]+$" s String s s public class Main {

    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int A = scanner.nextInt();
        int B = scanner.nextInt();
        String S = scanner.next();

        String Asub = S.substring(0, A);
        String Bsub = S.substring(A+1, A+B+1);

        /*
        System.out.println("Asub：" + Asub);
        System.out.println(isNum(Asub));
        System.out.println("Bsub：" + Bsub);
        System.out.println(isNum(Bsub));
        */

        String result = "No";
        //文字列が数字かつ、文字列のA+1番目がハイフン
        if (isNum(Asub) && isNum(Bsub) && S.substring(A, A+1).equals("-")) {
            result = "Yes";
        }
        System.out.println(result);
    }

    //文字列が数字か判定
    public static boolean isNum(String s) {
        return Pattern.compile("^-?[0-9]+$").matcher(s).find();
    }

} public class Main {

    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int A = scanner.nextInt();
        int B = scanner.nextInt();
        String S = scanner.next();

        String Asub = S.substring(0, A);
        String Bsub = S.substring(A+1, A+B+1);

        /*
        System.out.println("Asub：" + Asub);
        System.out.println(isNum(Asub));
        System.out.println("Bsub：" + Bsub);
        System.out.println(isNum(Bsub));
        */

        String result = "No";
        //文字列が数字かつ、文字列のA+1番目がハイフン
        if (isNum(Asub) && isNum(Bsub) && S.substring(A, A+1).equals("-")) {
            result = "Yes";
        }
        System.out.println(result);
    }

    //文字列が数字か判定
    public static boolean isNum(String s) {
        return Pattern.compile("^-?[0-9]+$").matcher(s).find();
    }

} Main
import java.util.Scanner;
import java.util.regex.Pattern;

public class Main {

    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int A = scanner.nextInt();
        int B = scanner.nextInt();
        String S = scanner.next();

        String Asub = S.substring(0, A);
        String Bsub = S.substring(A+1, A+B+1);

        /*
        System.out.println("Asub：" + Asub);
        System.out.println(isNum(Asub));
        System.out.println("Bsub：" + Bsub);
        System.out.println(isNum(Bsub));
        */

        String result = "No";
        //文字列が数字かつ、文字列のA+1番目がハイフン
        if (isNum(Asub) && isNum(Bsub) && S.substring(A, A+1).equals("-")) {
            result = "Yes";
        }
        System.out.println(result);
    }

    //文字列が数字か判定
    public static boolean isNum(String s) {
        return Pattern.compile("^-?[0-9]+$").matcher(s).find();
    }

}