import std.functional,
       std.algorithm,
       std.bigint,
       std.string,
       std.traits,
       std.array,
       std.range,
       std.stdio,
       std.conv;

bool isNumeric(char c) {
  return '0' <= c && c <= '9';
}

void main() {
  int[] AB = readln.chomp.split.to!(int[]);
  int A = AB[0],
      B = AB[1];
  string S = readln.chomp;

  foreach (i, c; S) {
    if (i == A) {
      if (!(c == '-')) {
        return writeln("No");
      }
    } else {
      if (!isNumeric(c)) {
        return writeln("No");
      }
    }
  }

  writeln("Yes");
}
