import java.io.IOException;

import java.io.BufferedReader;
import java.io.InputStreamReader;

public class Main {
    public static void main(String[] args) throws IOException {
        try (
            BufferedReader reader = new BufferedReader(
                new InputStreamReader(System.in))) {
            String s = reader.readLine();

            final String[] sl = s.split(" ");
            int A = Integer.parseInt(sl[0]);
            int B = Integer.parseInt(sl[1]);

            s = reader.readLine();

            boolean flg = false;

            if (s.length() == A + B + 1) {
                flg = true;
                for (int i = 0; i < A + B + 1; i++) {
                    if (A == i) {
                        if (s.charAt(i) == '-') {
                            continue;
                        } else {
                            flg = false;
                            break;
                        }
                    }

                    if (s.charAt(i) < '0' || '9' < s.charAt(i)) {
                        flg = false;
                        break;
                    }
                }
            }
            System.out.println(flg ? "Yes" : "No");
        }
    }
} import java.io.IOException; IOException java.io import java.io.BufferedReader; BufferedReader java.io import java.io.InputStreamReader; InputStreamReader java.io public class Main {
    public static void main(String[] args) throws IOException {
        try (
            BufferedReader reader = new BufferedReader(
                new InputStreamReader(System.in))) {
            String s = reader.readLine();

            final String[] sl = s.split(" ");
            int A = Integer.parseInt(sl[0]);
            int B = Integer.parseInt(sl[1]);

            s = reader.readLine();

            boolean flg = false;

            if (s.length() == A + B + 1) {
                flg = true;
                for (int i = 0; i < A + B + 1; i++) {
                    if (A == i) {
                        if (s.charAt(i) == '-') {
                            continue;
                        } else {
                            flg = false;
                            break;
                        }
                    }

                    if (s.charAt(i) < '0' || '9' < s.charAt(i)) {
                        flg = false;
                        break;
                    }
                }
            }
            System.out.println(flg ? "Yes" : "No");
        }
    }
} Main public static void main(String[] args) throws IOException {
        try (
            BufferedReader reader = new BufferedReader(
                new InputStreamReader(System.in))) {
            String s = reader.readLine();

            final String[] sl = s.split(" ");
            int A = Integer.parseInt(sl[0]);
            int B = Integer.parseInt(sl[1]);

            s = reader.readLine();

            boolean flg = false;

            if (s.length() == A + B + 1) {
                flg = true;
                for (int i = 0; i < A + B + 1; i++) {
                    if (A == i) {
                        if (s.charAt(i) == '-') {
                            continue;
                        } else {
                            flg = false;
                            break;
                        }
                    }

                    if (s.charAt(i) < '0' || '9' < s.charAt(i)) {
                        flg = false;
                        break;
                    }
                }
            }
            System.out.println(flg ? "Yes" : "No");
        }
    } main {
        try (
            BufferedReader reader = new BufferedReader(
                new InputStreamReader(System.in))) {
            String s = reader.readLine();

            final String[] sl = s.split(" ");
            int A = Integer.parseInt(sl[0]);
            int B = Integer.parseInt(sl[1]);

            s = reader.readLine();

            boolean flg = false;

            if (s.length() == A + B + 1) {
                flg = true;
                for (int i = 0; i < A + B + 1; i++) {
                    if (A == i) {
                        if (s.charAt(i) == '-') {
                            continue;
                        } else {
                            flg = false;
                            break;
                        }
                    }

                    if (s.charAt(i) < '0' || '9' < s.charAt(i)) {
                        flg = false;
                        break;
                    }
                }
            }
            System.out.println(flg ? "Yes" : "No");
        }
    } try (
            BufferedReader reader = new BufferedReader(
                new InputStreamReader(System.in))) {
            String s = reader.readLine();

            final String[] sl = s.split(" ");
            int A = Integer.parseInt(sl[0]);
            int B = Integer.parseInt(sl[1]);

            s = reader.readLine();

            boolean flg = false;

            if (s.length() == A + B + 1) {
                flg = true;
                for (int i = 0; i < A + B + 1; i++) {
                    if (A == i) {
                        if (s.charAt(i) == '-') {
                            continue;
                        } else {
                            flg = false;
                            break;
                        }
                    }

                    if (s.charAt(i) < '0' || '9' < s.charAt(i)) {
                        flg = false;
                        break;
                    }
                }
            }
            System.out.println(flg ? "Yes" : "No");
        } {
            String s = reader.readLine();

            final String[] sl = s.split(" ");
            int A = Integer.parseInt(sl[0]);
            int B = Integer.parseInt(sl[1]);

            s = reader.readLine();

            boolean flg = false;

            if (s.length() == A + B + 1) {
                flg = true;
                for (int i = 0; i < A + B + 1; i++) {
                    if (A == i) {
                        if (s.charAt(i) == '-') {
                            continue;
                        } else {
                            flg = false;
                            break;
                        }
                    }

                    if (s.charAt(i) < '0' || '9' < s.charAt(i)) {
                        flg = false;
                        break;
                    }
                }
            }
            System.out.println(flg ? "Yes" : "No");
        } BufferedReader reader = new BufferedReader(
                new InputStreamReader(System.in)) BufferedReader reader = new BufferedReader(
                new InputStreamReader(System.in)) new BufferedReader(
                new InputStreamReader(System.in)) String s = reader.readLine(); s reader.readLine() reader.readLine reader final String[] sl = s.split(" "); sl s.split(" ") s.split s " " int A = Integer.parseInt(sl[0]); A Integer.parseInt(sl[0]) Integer.parseInt Integer sl[0] sl 0 int B = Integer.parseInt(sl[1]); B Integer.parseInt(sl[1]) Integer.parseInt Integer sl[1] sl 1 s = reader.readLine() s reader.readLine() reader.readLine reader boolean flg = false; flg false if (s.length() == A + B + 1) {
                flg = true;
                for (int i = 0; i < A + B + 1; i++) {
                    if (A == i) {
                        if (s.charAt(i) == '-') {
                            continue;
                        } else {
                            flg = false;
                            break;
                        }
                    }

                    if (s.charAt(i) < '0' || '9' < s.charAt(i)) {
                        flg = false;
                        break;
                    }
                }
            } s.length() == A + B + 1 s.length() s.length s A + B + 1 A + B + 1 A B 1 {
                flg = true;
                for (int i = 0; i < A + B + 1; i++) {
                    if (A == i) {
                        if (s.charAt(i) == '-') {
                            continue;
                        } else {
                            flg = false;
                            break;
                        }
                    }

                    if (s.charAt(i) < '0' || '9' < s.charAt(i)) {
                        flg = false;
                        break;
                    }
                }
            } flg = true flg true for (int i = 0; i < A + B + 1; i++) {
                    if (A == i) {
                        if (s.charAt(i) == '-') {
                            continue;
                        } else {
                            flg = false;
                            break;
                        }
                    }

                    if (s.charAt(i) < '0' || '9' < s.charAt(i)) {
                        flg = false;
                        break;
                    }
                } 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 (A == i) {
                        if (s.charAt(i) == '-') {
                            continue;
                        } else {
                            flg = false;
                            break;
                        }
                    }

                    if (s.charAt(i) < '0' || '9' < s.charAt(i)) {
                        flg = false;
                        break;
                    }
                } {
                    if (A == i) {
                        if (s.charAt(i) == '-') {
                            continue;
                        } else {
                            flg = false;
                            break;
                        }
                    }

                    if (s.charAt(i) < '0' || '9' < s.charAt(i)) {
                        flg = false;
                        break;
                    }
                } if (A == i) {
                        if (s.charAt(i) == '-') {
                            continue;
                        } else {
                            flg = false;
                            break;
                        }
                    } A == i A i {
                        if (s.charAt(i) == '-') {
                            continue;
                        } else {
                            flg = false;
                            break;
                        }
                    } if (s.charAt(i) == '-') {
                            continue;
                        } else {
                            flg = false;
                            break;
                        } s.charAt(i) == '-' s.charAt(i) s.charAt s i '-' {
                            continue;
                        } continue; {
                            flg = false;
                            break;
                        } flg = false flg false break; if (s.charAt(i) < '0' || '9' < s.charAt(i)) {
                        flg = false;
                        break;
                    } s.charAt(i) < '0' || '9' < s.charAt(i) s.charAt(i) < '0' s.charAt(i) s.charAt s i '0' '9' < s.charAt(i) '9' s.charAt(i) s.charAt s i {
                        flg = false;
                        break;
                    } flg = false flg false break; System.out.println(flg ? "Yes" : "No") System.out.println System.out System System.out flg ? "Yes" : "No" flg "Yes" "No" String[] args args public class Main {
    public static void main(String[] args) throws IOException {
        try (
            BufferedReader reader = new BufferedReader(
                new InputStreamReader(System.in))) {
            String s = reader.readLine();

            final String[] sl = s.split(" ");
            int A = Integer.parseInt(sl[0]);
            int B = Integer.parseInt(sl[1]);

            s = reader.readLine();

            boolean flg = false;

            if (s.length() == A + B + 1) {
                flg = true;
                for (int i = 0; i < A + B + 1; i++) {
                    if (A == i) {
                        if (s.charAt(i) == '-') {
                            continue;
                        } else {
                            flg = false;
                            break;
                        }
                    }

                    if (s.charAt(i) < '0' || '9' < s.charAt(i)) {
                        flg = false;
                        break;
                    }
                }
            }
            System.out.println(flg ? "Yes" : "No");
        }
    }
} public class Main {
    public static void main(String[] args) throws IOException {
        try (
            BufferedReader reader = new BufferedReader(
                new InputStreamReader(System.in))) {
            String s = reader.readLine();

            final String[] sl = s.split(" ");
            int A = Integer.parseInt(sl[0]);
            int B = Integer.parseInt(sl[1]);

            s = reader.readLine();

            boolean flg = false;

            if (s.length() == A + B + 1) {
                flg = true;
                for (int i = 0; i < A + B + 1; i++) {
                    if (A == i) {
                        if (s.charAt(i) == '-') {
                            continue;
                        } else {
                            flg = false;
                            break;
                        }
                    }

                    if (s.charAt(i) < '0' || '9' < s.charAt(i)) {
                        flg = false;
                        break;
                    }
                }
            }
            System.out.println(flg ? "Yes" : "No");
        }
    }
} Main
import java.io.IOException;

import java.io.BufferedReader;
import java.io.InputStreamReader;

public class Main {
    public static void main(String[] args) throws IOException {
        try (
            BufferedReader reader = new BufferedReader(
                new InputStreamReader(System.in))) {
            String s = reader.readLine();

            final String[] sl = s.split(" ");
            int A = Integer.parseInt(sl[0]);
            int B = Integer.parseInt(sl[1]);

            s = reader.readLine();

            boolean flg = false;

            if (s.length() == A + B + 1) {
                flg = true;
                for (int i = 0; i < A + B + 1; i++) {
                    if (A == i) {
                        if (s.charAt(i) == '-') {
                            continue;
                        } else {
                            flg = false;
                            break;
                        }
                    }

                    if (s.charAt(i) < '0' || '9' < s.charAt(i)) {
                        flg = false;
                        break;
                    }
                }
            }
            System.out.println(flg ? "Yes" : "No");
        }
    }
}
