import java.util.Scanner;

public class Main {

    public static void main(String[] args) {
        @SuppressWarnings("resource")
        Scanner sc = new Scanner(System.in);
        int a = sc.nextInt();
        int b = sc.nextInt();
        char[] s = sc.next().toCharArray();
        boolean flg = true;
        for (int i = 0 ; i < a + b + 1 ; i++) {
            if (i == a) {
                if (s[i] != '-') flg = false;
            } else {
                if (s[i] == '-') flg = false;
            }
        }
        System.out.println(flg ? "Yes" : "No");
    }

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

    public static void main(String[] args) {
        @SuppressWarnings("resource")
        Scanner sc = new Scanner(System.in);
        int a = sc.nextInt();
        int b = sc.nextInt();
        char[] s = sc.next().toCharArray();
        boolean flg = true;
        for (int i = 0 ; i < a + b + 1 ; i++) {
            if (i == a) {
                if (s[i] != '-') flg = false;
            } else {
                if (s[i] == '-') flg = false;
            }
        }
        System.out.println(flg ? "Yes" : "No");
    }

} Main public static void main(String[] args) {
        @SuppressWarnings("resource")
        Scanner sc = new Scanner(System.in);
        int a = sc.nextInt();
        int b = sc.nextInt();
        char[] s = sc.next().toCharArray();
        boolean flg = true;
        for (int i = 0 ; i < a + b + 1 ; i++) {
            if (i == a) {
                if (s[i] != '-') flg = false;
            } else {
                if (s[i] == '-') flg = false;
            }
        }
        System.out.println(flg ? "Yes" : "No");
    } main {
        @SuppressWarnings("resource")
        Scanner sc = new Scanner(System.in);
        int a = sc.nextInt();
        int b = sc.nextInt();
        char[] s = sc.next().toCharArray();
        boolean flg = true;
        for (int i = 0 ; i < a + b + 1 ; i++) {
            if (i == a) {
                if (s[i] != '-') flg = false;
            } else {
                if (s[i] == '-') flg = false;
            }
        }
        System.out.println(flg ? "Yes" : "No");
    } @SuppressWarnings("resource")
        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 char[] s = sc.next().toCharArray(); s sc.next().toCharArray() sc.next().toCharArray sc.next() sc.next sc boolean flg = true; flg true for (int i = 0 ; i < a + b + 1 ; i++) {
            if (i == a) {
                if (s[i] != '-') flg = false;
            } else {
                if (s[i] == '-') flg = false;
            }
        } 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[i] != '-') flg = false;
            } else {
                if (s[i] == '-') flg = false;
            }
        } {
            if (i == a) {
                if (s[i] != '-') flg = false;
            } else {
                if (s[i] == '-') flg = false;
            }
        } if (i == a) {
                if (s[i] != '-') flg = false;
            } else {
                if (s[i] == '-') flg = false;
            } i == a i a {
                if (s[i] != '-') flg = false;
            } if (s[i] != '-') flg = false; s[i] != '-' s[i] s i '-' flg = false flg false {
                if (s[i] == '-') flg = false;
            } if (s[i] == '-') flg = false; s[i] == '-' s[i] s i '-' flg = false flg false 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) {
        @SuppressWarnings("resource")
        Scanner sc = new Scanner(System.in);
        int a = sc.nextInt();
        int b = sc.nextInt();
        char[] s = sc.next().toCharArray();
        boolean flg = true;
        for (int i = 0 ; i < a + b + 1 ; i++) {
            if (i == a) {
                if (s[i] != '-') flg = false;
            } else {
                if (s[i] == '-') flg = false;
            }
        }
        System.out.println(flg ? "Yes" : "No");
    }

} public class Main {

    public static void main(String[] args) {
        @SuppressWarnings("resource")
        Scanner sc = new Scanner(System.in);
        int a = sc.nextInt();
        int b = sc.nextInt();
        char[] s = sc.next().toCharArray();
        boolean flg = true;
        for (int i = 0 ; i < a + b + 1 ; i++) {
            if (i == a) {
                if (s[i] != '-') flg = false;
            } else {
                if (s[i] == '-') flg = false;
            }
        }
        System.out.println(flg ? "Yes" : "No");
    }

} Main
import java.util.Scanner;

public class Main {

    public static void main(String[] args) {
        @SuppressWarnings("resource")
        Scanner sc = new Scanner(System.in);
        int a = sc.nextInt();
        int b = sc.nextInt();
        char[] s = sc.next().toCharArray();
        boolean flg = true;
        for (int i = 0 ; i < a + b + 1 ; i++) {
            if (i == a) {
                if (s[i] != '-') flg = false;
            } else {
                if (s[i] == '-') flg = false;
            }
        }
        System.out.println(flg ? "Yes" : "No");
    }

}