public static void main ( String [ ] args ) {
  Scanner sc = new Scanner ( System . in ) ;
  int a = sc . nextInt ( ) ;
  int b = sc . nextInt ( ) ;
  int length = a + b + 1 ;
  String post = sc . next ( ) ;
  char c = post . charAt ( a ) ;
  String start = post . substring ( 0 , a ) ;
  String end = post . substring ( a + 1 , post . length ( ) ) ;
  String ans = "" ;
  if ( post . length ( ) == length ) {
    if ( c == '-' ) {
      if ( start . contains ( "-" ) || end . contains ( "-" ) ) {
        ans = "No" ;
      }
      else {
        ans = "Yes" ;
      }
    }
    else {
      ans = "No" ;
    }
  }
  else {
    ans = "No" ;
  }
  System . out . println ( ans ) ;
}

public static void main ( String [ ] args ) { Scanner sc = new Scanner ( System . in ) ; int a = sc . nextInt ( ) ; int b = sc . nextInt ( ) ; int length = a + b + 1 ; String post = sc . next ( ) ; char c = post . charAt ( a ) ; String start = post . substring ( 0 , a ) ; String end = post . substring ( a + 1 , post . length ( ) ) ; String ans = " " ; if ( post . length ( ) == length ) { if ( c == ' - ' ) { if ( start . contains ( " - " ) || end . contains ( " - " ) ) { ans = " No " ; } else { ans = " Yes " ; } } else { ans = " No " ; } } else { ans = " No " ; } System . out . println ( ans ) ; }
(method_declaration (modifiers) type: (void_type) name: (identifier) parameters: (formal_parameters (formal_parameter type: (array_type element: (type_identifier) dimensions: (dimensions)) name: (identifier))) body: (block (local_variable_declaration type: (type_identifier) declarator: (variable_declarator name: (identifier) value: (object_creation_expression type: (type_identifier) arguments: (argument_list (field_access object: (identifier) field: (identifier)))))) (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier) value: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list)))) (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier) value: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list)))) (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier) value: (binary_expression left: (binary_expression left: (identifier) right: (identifier)) right: (decimal_integer_literal)))) (local_variable_declaration type: (type_identifier) declarator: (variable_declarator name: (identifier) value: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list)))) (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier) value: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list (identifier))))) (local_variable_declaration type: (type_identifier) declarator: (variable_declarator name: (identifier) value: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list (decimal_integer_literal) (identifier))))) (local_variable_declaration type: (type_identifier) declarator: (variable_declarator name: (identifier) value: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list (binary_expression left: (identifier) right: (decimal_integer_literal)) (method_invocation object: (identifier) name: (identifier) arguments: (argument_list)))))) (local_variable_declaration type: (type_identifier) declarator: (variable_declarator name: (identifier) value: (string_literal))) (if_statement condition: (parenthesized_expression (binary_expression left: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list)) right: (identifier))) consequence: (block (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (character_literal))) consequence: (block (if_statement condition: (parenthesized_expression (binary_expression left: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list (string_literal))) right: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list (string_literal))))) consequence: (block (expression_statement (assignment_expression left: (identifier) right: (string_literal)))) alternative: (block (expression_statement (assignment_expression left: (identifier) right: (string_literal)))))) alternative: (block (expression_statement (assignment_expression left: (identifier) right: (string_literal)))))) alternative: (block (expression_statement (assignment_expression left: (identifier) right: (string_literal))))) (expression_statement (method_invocation object: (field_access object: (identifier) field: (identifier)) name: (identifier) arguments: (argument_list (identifier))))))