

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

public class Main {
    static BufferedReader br = new BufferedReader(new InputStreamReader(System.in));

    public static void main(String[] args) throws Exception {
        int[] arr = inputval();
        int A, B;
        String S;
        A = arr[0];
        B = arr[1];
        S = br.readLine().trim();
        String str = "No";

        for (int i = 0; i < A + B + 1; i++) {
            if (i == A) {
                if (S.charAt(i) != '-') break;
            }else{
                if(!('0' <= S.charAt(i) && S.charAt(i) <= '9')) break;
            }
            if(i==A+B) str = "Yes";
        }
        System.out.println(str);
    }


    static int[] inputval() throws Exception {
        String[] strarray = br.readLine().trim().split(" ");
        int[] intarray = new int[strarray.length];
        for (int i = 0; i < intarray.length; i++) {
            intarray[i] = Integer.parseInt(strarray[i]);
        }
        return intarray;
    }

    static void array_sout(int[][] array) {
        for (int i = 0; i < array.length; i++) {
            for (int j = 0; j < array[0].length; j++) {
                System.out.print(array[i][j] + " ");
            }
            System.out.println();
        }
    }

    static void array_sout(int[] array) {
        for (int i = 0; i < array.length; i++) {
            System.out.print(array[i] + " ");
        }
        System.out.println();
    }
} import java.io.BufferedReader; BufferedReader java.io import java.io.InputStreamReader; InputStreamReader java.io public class Main {
    static BufferedReader br = new BufferedReader(new InputStreamReader(System.in));

    public static void main(String[] args) throws Exception {
        int[] arr = inputval();
        int A, B;
        String S;
        A = arr[0];
        B = arr[1];
        S = br.readLine().trim();
        String str = "No";

        for (int i = 0; i < A + B + 1; i++) {
            if (i == A) {
                if (S.charAt(i) != '-') break;
            }else{
                if(!('0' <= S.charAt(i) && S.charAt(i) <= '9')) break;
            }
            if(i==A+B) str = "Yes";
        }
        System.out.println(str);
    }


    static int[] inputval() throws Exception {
        String[] strarray = br.readLine().trim().split(" ");
        int[] intarray = new int[strarray.length];
        for (int i = 0; i < intarray.length; i++) {
            intarray[i] = Integer.parseInt(strarray[i]);
        }
        return intarray;
    }

    static void array_sout(int[][] array) {
        for (int i = 0; i < array.length; i++) {
            for (int j = 0; j < array[0].length; j++) {
                System.out.print(array[i][j] + " ");
            }
            System.out.println();
        }
    }

    static void array_sout(int[] array) {
        for (int i = 0; i < array.length; i++) {
            System.out.print(array[i] + " ");
        }
        System.out.println();
    }
} Main static BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); br new BufferedReader(new InputStreamReader(System.in)) public static void main(String[] args) throws Exception {
        int[] arr = inputval();
        int A, B;
        String S;
        A = arr[0];
        B = arr[1];
        S = br.readLine().trim();
        String str = "No";

        for (int i = 0; i < A + B + 1; i++) {
            if (i == A) {
                if (S.charAt(i) != '-') break;
            }else{
                if(!('0' <= S.charAt(i) && S.charAt(i) <= '9')) break;
            }
            if(i==A+B) str = "Yes";
        }
        System.out.println(str);
    } main {
        int[] arr = inputval();
        int A, B;
        String S;
        A = arr[0];
        B = arr[1];
        S = br.readLine().trim();
        String str = "No";

        for (int i = 0; i < A + B + 1; i++) {
            if (i == A) {
                if (S.charAt(i) != '-') break;
            }else{
                if(!('0' <= S.charAt(i) && S.charAt(i) <= '9')) break;
            }
            if(i==A+B) str = "Yes";
        }
        System.out.println(str);
    } int[] arr = inputval(); arr inputval() inputval int A A B; B String S; S A = arr[0] A arr[0] arr 0 B = arr[1] B arr[1] arr 1 S = br.readLine().trim() S br.readLine().trim() br.readLine().trim br.readLine() br.readLine br String str = "No"; str "No" for (int i = 0; i < A + B + 1; i++) {
            if (i == A) {
                if (S.charAt(i) != '-') break;
            }else{
                if(!('0' <= S.charAt(i) && S.charAt(i) <= '9')) break;
            }
            if(i==A+B) str = "Yes";
        } 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) != '-') break;
            }else{
                if(!('0' <= S.charAt(i) && S.charAt(i) <= '9')) break;
            }
            if(i==A+B) str = "Yes";
        } {
            if (i == A) {
                if (S.charAt(i) != '-') break;
            }else{
                if(!('0' <= S.charAt(i) && S.charAt(i) <= '9')) break;
            }
            if(i==A+B) str = "Yes";
        } if (i == A) {
                if (S.charAt(i) != '-') break;
            }else{
                if(!('0' <= S.charAt(i) && S.charAt(i) <= '9')) break;
            } i == A i A {
                if (S.charAt(i) != '-') break;
            } if (S.charAt(i) != '-') break; S.charAt(i) != '-' S.charAt(i) S.charAt S i '-' break; {
                if(!('0' <= S.charAt(i) && S.charAt(i) <= '9')) break;
            } if(!('0' <= S.charAt(i) && S.charAt(i) <= '9')) break; !('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' break; if(i==A+B) str = "Yes"; i==A+B i A+B A B str = "Yes" str "Yes" System.out.println(str) System.out.println System.out System System.out str String[] args args static int[] inputval() throws Exception {
        String[] strarray = br.readLine().trim().split(" ");
        int[] intarray = new int[strarray.length];
        for (int i = 0; i < intarray.length; i++) {
            intarray[i] = Integer.parseInt(strarray[i]);
        }
        return intarray;
    } inputval {
        String[] strarray = br.readLine().trim().split(" ");
        int[] intarray = new int[strarray.length];
        for (int i = 0; i < intarray.length; i++) {
            intarray[i] = Integer.parseInt(strarray[i]);
        }
        return intarray;
    } String[] strarray = br.readLine().trim().split(" "); strarray br.readLine().trim().split(" ") br.readLine().trim().split br.readLine().trim() br.readLine().trim br.readLine() br.readLine br " " int[] intarray = new int[strarray.length]; intarray new int[strarray.length] strarray.length strarray strarray.length for (int i = 0; i < intarray.length; i++) {
            intarray[i] = Integer.parseInt(strarray[i]);
        } int i = 0; int i = 0; i 0 i < intarray.length i intarray.length intarray intarray.length i++ i++ i {
            intarray[i] = Integer.parseInt(strarray[i]);
        } {
            intarray[i] = Integer.parseInt(strarray[i]);
        } intarray[i] = Integer.parseInt(strarray[i]) intarray[i] intarray i Integer.parseInt(strarray[i]) Integer.parseInt Integer strarray[i] strarray i return intarray; intarray static void array_sout(int[][] array) {
        for (int i = 0; i < array.length; i++) {
            for (int j = 0; j < array[0].length; j++) {
                System.out.print(array[i][j] + " ");
            }
            System.out.println();
        }
    } array_sout {
        for (int i = 0; i < array.length; i++) {
            for (int j = 0; j < array[0].length; j++) {
                System.out.print(array[i][j] + " ");
            }
            System.out.println();
        }
    } for (int i = 0; i < array.length; i++) {
            for (int j = 0; j < array[0].length; j++) {
                System.out.print(array[i][j] + " ");
            }
            System.out.println();
        } int i = 0; int i = 0; i 0 i < array.length i array.length array array.length i++ i++ i {
            for (int j = 0; j < array[0].length; j++) {
                System.out.print(array[i][j] + " ");
            }
            System.out.println();
        } {
            for (int j = 0; j < array[0].length; j++) {
                System.out.print(array[i][j] + " ");
            }
            System.out.println();
        } for (int j = 0; j < array[0].length; j++) {
                System.out.print(array[i][j] + " ");
            } int j = 0; int j = 0; j 0 j < array[0].length j array[0].length array[0] array 0 array[0].length j++ j++ j {
                System.out.print(array[i][j] + " ");
            } {
                System.out.print(array[i][j] + " ");
            } System.out.print(array[i][j] + " ") System.out.print System.out System System.out array[i][j] + " " array[i][j] array[i] array i j " " System.out.println() System.out.println System.out System System.out int[][] array array static void array_sout(int[] array) {
        for (int i = 0; i < array.length; i++) {
            System.out.print(array[i] + " ");
        }
        System.out.println();
    } array_sout {
        for (int i = 0; i < array.length; i++) {
            System.out.print(array[i] + " ");
        }
        System.out.println();
    } for (int i = 0; i < array.length; i++) {
            System.out.print(array[i] + " ");
        } int i = 0; int i = 0; i 0 i < array.length i array.length array array.length i++ i++ i {
            System.out.print(array[i] + " ");
        } {
            System.out.print(array[i] + " ");
        } System.out.print(array[i] + " ") System.out.print System.out System System.out array[i] + " " array[i] array i " " System.out.println() System.out.println System.out System System.out int[] array array public class Main {
    static BufferedReader br = new BufferedReader(new InputStreamReader(System.in));

    public static void main(String[] args) throws Exception {
        int[] arr = inputval();
        int A, B;
        String S;
        A = arr[0];
        B = arr[1];
        S = br.readLine().trim();
        String str = "No";

        for (int i = 0; i < A + B + 1; i++) {
            if (i == A) {
                if (S.charAt(i) != '-') break;
            }else{
                if(!('0' <= S.charAt(i) && S.charAt(i) <= '9')) break;
            }
            if(i==A+B) str = "Yes";
        }
        System.out.println(str);
    }


    static int[] inputval() throws Exception {
        String[] strarray = br.readLine().trim().split(" ");
        int[] intarray = new int[strarray.length];
        for (int i = 0; i < intarray.length; i++) {
            intarray[i] = Integer.parseInt(strarray[i]);
        }
        return intarray;
    }

    static void array_sout(int[][] array) {
        for (int i = 0; i < array.length; i++) {
            for (int j = 0; j < array[0].length; j++) {
                System.out.print(array[i][j] + " ");
            }
            System.out.println();
        }
    }

    static void array_sout(int[] array) {
        for (int i = 0; i < array.length; i++) {
            System.out.print(array[i] + " ");
        }
        System.out.println();
    }
} public class Main {
    static BufferedReader br = new BufferedReader(new InputStreamReader(System.in));

    public static void main(String[] args) throws Exception {
        int[] arr = inputval();
        int A, B;
        String S;
        A = arr[0];
        B = arr[1];
        S = br.readLine().trim();
        String str = "No";

        for (int i = 0; i < A + B + 1; i++) {
            if (i == A) {
                if (S.charAt(i) != '-') break;
            }else{
                if(!('0' <= S.charAt(i) && S.charAt(i) <= '9')) break;
            }
            if(i==A+B) str = "Yes";
        }
        System.out.println(str);
    }


    static int[] inputval() throws Exception {
        String[] strarray = br.readLine().trim().split(" ");
        int[] intarray = new int[strarray.length];
        for (int i = 0; i < intarray.length; i++) {
            intarray[i] = Integer.parseInt(strarray[i]);
        }
        return intarray;
    }

    static void array_sout(int[][] array) {
        for (int i = 0; i < array.length; i++) {
            for (int j = 0; j < array[0].length; j++) {
                System.out.print(array[i][j] + " ");
            }
            System.out.println();
        }
    }

    static void array_sout(int[] array) {
        for (int i = 0; i < array.length; i++) {
            System.out.print(array[i] + " ");
        }
        System.out.println();
    }
} Main


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

public class Main {
    static BufferedReader br = new BufferedReader(new InputStreamReader(System.in));

    public static void main(String[] args) throws Exception {
        int[] arr = inputval();
        int A, B;
        String S;
        A = arr[0];
        B = arr[1];
        S = br.readLine().trim();
        String str = "No";

        for (int i = 0; i < A + B + 1; i++) {
            if (i == A) {
                if (S.charAt(i) != '-') break;
            }else{
                if(!('0' <= S.charAt(i) && S.charAt(i) <= '9')) break;
            }
            if(i==A+B) str = "Yes";
        }
        System.out.println(str);
    }


    static int[] inputval() throws Exception {
        String[] strarray = br.readLine().trim().split(" ");
        int[] intarray = new int[strarray.length];
        for (int i = 0; i < intarray.length; i++) {
            intarray[i] = Integer.parseInt(strarray[i]);
        }
        return intarray;
    }

    static void array_sout(int[][] array) {
        for (int i = 0; i < array.length; i++) {
            for (int j = 0; j < array[0].length; j++) {
                System.out.print(array[i][j] + " ");
            }
            System.out.println();
        }
    }

    static void array_sout(int[] array) {
        for (int i = 0; i < array.length; i++) {
            System.out.print(array[i] + " ");
        }
        System.out.println();
    }
}