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

class Main{


	public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		int A = scanner.nextInt();
		int B = scanner.nextInt();
		String string = scanner.next();
		String mae = string.substring(0,A);
		String naka = string.substring(A,A+1);
		String ushiro = string.substring(A+2);
		Pattern p = Pattern.compile("^[0-9]*$");
		Matcher m = p.matcher(mae);
		Matcher u = p.matcher(ushiro);




		if(m.find() && u.find() && naka.equals("-")){
			System.out.println("Yes");
		}else{
			System.out.println("No");


		}



	}
}
class Pair implements Comparable{
	int from;
	int end;
	@Override
	public int compareTo(Object other) {
		Pair otherpair = (Pair)other;

		return end - otherpair.end;
	}
}
 import java.util.Scanner; Scanner java.util import java.util.regex.Matcher; Matcher java.util.regex import java.util.regex.Pattern; Pattern java.util.regex class Main{


	public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		int A = scanner.nextInt();
		int B = scanner.nextInt();
		String string = scanner.next();
		String mae = string.substring(0,A);
		String naka = string.substring(A,A+1);
		String ushiro = string.substring(A+2);
		Pattern p = Pattern.compile("^[0-9]*$");
		Matcher m = p.matcher(mae);
		Matcher u = p.matcher(ushiro);




		if(m.find() && u.find() && naka.equals("-")){
			System.out.println("Yes");
		}else{
			System.out.println("No");


		}



	}
} Main public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		int A = scanner.nextInt();
		int B = scanner.nextInt();
		String string = scanner.next();
		String mae = string.substring(0,A);
		String naka = string.substring(A,A+1);
		String ushiro = string.substring(A+2);
		Pattern p = Pattern.compile("^[0-9]*$");
		Matcher m = p.matcher(mae);
		Matcher u = p.matcher(ushiro);




		if(m.find() && u.find() && naka.equals("-")){
			System.out.println("Yes");
		}else{
			System.out.println("No");


		}



	} main {
		Scanner scanner = new Scanner(System.in);
		int A = scanner.nextInt();
		int B = scanner.nextInt();
		String string = scanner.next();
		String mae = string.substring(0,A);
		String naka = string.substring(A,A+1);
		String ushiro = string.substring(A+2);
		Pattern p = Pattern.compile("^[0-9]*$");
		Matcher m = p.matcher(mae);
		Matcher u = p.matcher(ushiro);




		if(m.find() && u.find() && naka.equals("-")){
			System.out.println("Yes");
		}else{
			System.out.println("No");


		}



	} 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 string = scanner.next(); string scanner.next() scanner.next scanner String mae = string.substring(0,A); mae string.substring(0,A) string.substring string 0 A String naka = string.substring(A,A+1); naka string.substring(A,A+1) string.substring string A A+1 A 1 String ushiro = string.substring(A+2); ushiro string.substring(A+2) string.substring string A+2 A 2 Pattern p = Pattern.compile("^[0-9]*$"); p Pattern.compile("^[0-9]*$") Pattern.compile Pattern "^[0-9]*$" Matcher m = p.matcher(mae); m p.matcher(mae) p.matcher p mae Matcher u = p.matcher(ushiro); u p.matcher(ushiro) p.matcher p ushiro if(m.find() && u.find() && naka.equals("-")){
			System.out.println("Yes");
		}else{
			System.out.println("No");


		} m.find() && u.find() && naka.equals("-") m.find() && u.find() && naka.equals("-") m.find() m.find m u.find() u.find u naka.equals("-") naka.equals naka "-" {
			System.out.println("Yes");
		} System.out.println("Yes") System.out.println System.out System System.out "Yes" {
			System.out.println("No");


		} System.out.println("No") System.out.println System.out System System.out "No" String[] args args class Pair implements Comparable{
	int from;
	int end;
	@Override
	public int compareTo(Object other) {
		Pair otherpair = (Pair)other;

		return end - otherpair.end;
	}
} Pair int from; from int end; end @Override
	public int compareTo(Object other) {
		Pair otherpair = (Pair)other;

		return end - otherpair.end;
	} compareTo {
		Pair otherpair = (Pair)other;

		return end - otherpair.end;
	} Pair otherpair = (Pair)other; otherpair (Pair)other return end - otherpair.end; end - otherpair.end end otherpair.end otherpair otherpair.end Object other other Comparable
import java.util.Scanner;
import java.util.regex.Matcher;
import java.util.regex.Pattern;

class Main{


	public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		int A = scanner.nextInt();
		int B = scanner.nextInt();
		String string = scanner.next();
		String mae = string.substring(0,A);
		String naka = string.substring(A,A+1);
		String ushiro = string.substring(A+2);
		Pattern p = Pattern.compile("^[0-9]*$");
		Matcher m = p.matcher(mae);
		Matcher u = p.matcher(ushiro);




		if(m.find() && u.find() && naka.equals("-")){
			System.out.println("Yes");
		}else{
			System.out.println("No");


		}



	}
}
class Pair implements Comparable{
	int from;
	int end;
	@Override
	public int compareTo(Object other) {
		Pair otherpair = (Pair)other;

		return end - otherpair.end;
	}
}

