import java.io.OutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.PrintWriter;
import java.util.Scanner;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 *
 * @author mikit
 */
public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        Scanner in = new Scanner(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        BPostalCode solver = new BPostalCode();
        solver.solve(1, in, out);
        out.close();
    }

    static class BPostalCode {
        public void solve(int testNumber, Scanner in, PrintWriter out) {
            int a = in.nextInt(), b = in.nextInt();
            String s = in.next();
            for (int i = 0; i < s.length(); i++) {
                if (i == a) {
                    if (s.charAt(i) != '-') {
                        out.println("No");
                        return;
                    }
                } else {
                    if (!Character.isDigit(s.charAt(i))) {
                        out.println("No");
                        return;
                    }
                }
            }
            out.println("Yes");
        }

    }
}
 import java.io.OutputStream; OutputStream java.io import java.io.IOException; IOException java.io import java.io.InputStream; InputStream java.io import java.io.PrintWriter; PrintWriter java.io import java.util.Scanner; Scanner java.util public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        Scanner in = new Scanner(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        BPostalCode solver = new BPostalCode();
        solver.solve(1, in, out);
        out.close();
    }

    static class BPostalCode {
        public void solve(int testNumber, Scanner in, PrintWriter out) {
            int a = in.nextInt(), b = in.nextInt();
            String s = in.next();
            for (int i = 0; i < s.length(); i++) {
                if (i == a) {
                    if (s.charAt(i) != '-') {
                        out.println("No");
                        return;
                    }
                } else {
                    if (!Character.isDigit(s.charAt(i))) {
                        out.println("No");
                        return;
                    }
                }
            }
            out.println("Yes");
        }

    }
} Main public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        Scanner in = new Scanner(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        BPostalCode solver = new BPostalCode();
        solver.solve(1, in, out);
        out.close();
    } main {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        Scanner in = new Scanner(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        BPostalCode solver = new BPostalCode();
        solver.solve(1, in, out);
        out.close();
    } InputStream inputStream = System.in; inputStream System.in System System.in OutputStream outputStream = System.out; outputStream System.out System System.out Scanner in = new Scanner(inputStream); in new Scanner(inputStream) PrintWriter out = new PrintWriter(outputStream); out new PrintWriter(outputStream) BPostalCode solver = new BPostalCode(); solver new BPostalCode() solver.solve(1, in, out) solver.solve solver 1 in out out.close() out.close out String[] args args static class BPostalCode {
        public void solve(int testNumber, Scanner in, PrintWriter out) {
            int a = in.nextInt(), b = in.nextInt();
            String s = in.next();
            for (int i = 0; i < s.length(); i++) {
                if (i == a) {
                    if (s.charAt(i) != '-') {
                        out.println("No");
                        return;
                    }
                } else {
                    if (!Character.isDigit(s.charAt(i))) {
                        out.println("No");
                        return;
                    }
                }
            }
            out.println("Yes");
        }

    } BPostalCode public void solve(int testNumber, Scanner in, PrintWriter out) {
            int a = in.nextInt(), b = in.nextInt();
            String s = in.next();
            for (int i = 0; i < s.length(); i++) {
                if (i == a) {
                    if (s.charAt(i) != '-') {
                        out.println("No");
                        return;
                    }
                } else {
                    if (!Character.isDigit(s.charAt(i))) {
                        out.println("No");
                        return;
                    }
                }
            }
            out.println("Yes");
        } solve {
            int a = in.nextInt(), b = in.nextInt();
            String s = in.next();
            for (int i = 0; i < s.length(); i++) {
                if (i == a) {
                    if (s.charAt(i) != '-') {
                        out.println("No");
                        return;
                    }
                } else {
                    if (!Character.isDigit(s.charAt(i))) {
                        out.println("No");
                        return;
                    }
                }
            }
            out.println("Yes");
        } int a = in.nextInt() a in.nextInt() in.nextInt in b = in.nextInt(); b in.nextInt() in.nextInt in String s = in.next(); s in.next() in.next in for (int i = 0; i < s.length(); i++) {
                if (i == a) {
                    if (s.charAt(i) != '-') {
                        out.println("No");
                        return;
                    }
                } else {
                    if (!Character.isDigit(s.charAt(i))) {
                        out.println("No");
                        return;
                    }
                }
            } 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) != '-') {
                        out.println("No");
                        return;
                    }
                } else {
                    if (!Character.isDigit(s.charAt(i))) {
                        out.println("No");
                        return;
                    }
                }
            } {
                if (i == a) {
                    if (s.charAt(i) != '-') {
                        out.println("No");
                        return;
                    }
                } else {
                    if (!Character.isDigit(s.charAt(i))) {
                        out.println("No");
                        return;
                    }
                }
            } if (i == a) {
                    if (s.charAt(i) != '-') {
                        out.println("No");
                        return;
                    }
                } else {
                    if (!Character.isDigit(s.charAt(i))) {
                        out.println("No");
                        return;
                    }
                } i == a i a {
                    if (s.charAt(i) != '-') {
                        out.println("No");
                        return;
                    }
                } if (s.charAt(i) != '-') {
                        out.println("No");
                        return;
                    } s.charAt(i) != '-' s.charAt(i) s.charAt s i '-' {
                        out.println("No");
                        return;
                    } out.println("No") out.println out "No" return; {
                    if (!Character.isDigit(s.charAt(i))) {
                        out.println("No");
                        return;
                    }
                } if (!Character.isDigit(s.charAt(i))) {
                        out.println("No");
                        return;
                    } !Character.isDigit(s.charAt(i)) Character.isDigit(s.charAt(i)) Character.isDigit Character s.charAt(i) s.charAt s i {
                        out.println("No");
                        return;
                    } out.println("No") out.println out "No" return; out.println("Yes") out.println out "Yes" int testNumber testNumber Scanner in in PrintWriter out out public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        Scanner in = new Scanner(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        BPostalCode solver = new BPostalCode();
        solver.solve(1, in, out);
        out.close();
    }

    static class BPostalCode {
        public void solve(int testNumber, Scanner in, PrintWriter out) {
            int a = in.nextInt(), b = in.nextInt();
            String s = in.next();
            for (int i = 0; i < s.length(); i++) {
                if (i == a) {
                    if (s.charAt(i) != '-') {
                        out.println("No");
                        return;
                    }
                } else {
                    if (!Character.isDigit(s.charAt(i))) {
                        out.println("No");
                        return;
                    }
                }
            }
            out.println("Yes");
        }

    }
} public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        Scanner in = new Scanner(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        BPostalCode solver = new BPostalCode();
        solver.solve(1, in, out);
        out.close();
    }

    static class BPostalCode {
        public void solve(int testNumber, Scanner in, PrintWriter out) {
            int a = in.nextInt(), b = in.nextInt();
            String s = in.next();
            for (int i = 0; i < s.length(); i++) {
                if (i == a) {
                    if (s.charAt(i) != '-') {
                        out.println("No");
                        return;
                    }
                } else {
                    if (!Character.isDigit(s.charAt(i))) {
                        out.println("No");
                        return;
                    }
                }
            }
            out.println("Yes");
        }

    }
} Main
import java.io.OutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.PrintWriter;
import java.util.Scanner;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 *
 * @author mikit
 */
public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        Scanner in = new Scanner(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        BPostalCode solver = new BPostalCode();
        solver.solve(1, in, out);
        out.close();
    }

    static class BPostalCode {
        public void solve(int testNumber, Scanner in, PrintWriter out) {
            int a = in.nextInt(), b = in.nextInt();
            String s = in.next();
            for (int i = 0; i < s.length(); i++) {
                if (i == a) {
                    if (s.charAt(i) != '-') {
                        out.println("No");
                        return;
                    }
                } else {
                    if (!Character.isDigit(s.charAt(i))) {
                        out.println("No");
                        return;
                    }
                }
            }
            out.println("Yes");
        }

    }
}

