public static void main ( String [ ] args ) {
  int h = 0 ;
  int w = 0 ;
  char [ ] [ ] square = null ;
  String [ ] tmp = null ;
  try ( BufferedReader br = new BufferedReader ( new InputStreamReader ( System . in ) ) ) {
    tmp = br . readLine ( ) . split ( "\\s" ) ;
    h = Integer . parseInt ( tmp [ 0 ] ) ;
    w = Integer . parseInt ( tmp [ 1 ] ) ;
    square = new char [ h ] [ w ] ;
    for ( int i = 0 ;
    i < h ;
    i ++ ) {
      square [ i ] = br . readLine ( ) . toCharArray ( ) ;
    }
  }
  catch ( IOException e ) {
    e . printStackTrace ( ) ;
    System . exit ( 1 ) ;
  }
  boolean result = true ;
  parentLoop : for ( int i = 0 ;
  i < square . length ;
  i ++ ) {
    final char [ ] line = square [ i ] ;
    for ( int j = 0 ;
    j < line . length ;
    j ++ ) {
      if ( line [ j ] == '#' ) {
        if ( 0 <= i - 1 && square [ i - 1 ] [ j ] != '#' ) {
          if ( i + 1 < h && square [ i + 1 ] [ j ] != '#' ) {
            if ( 0 <= j - 1 && square [ i ] [ j - 1 ] != '#' ) {
              if ( j + 1 < w && square [ i ] [ j + 1 ] != '#' ) {
                result = false ;
                break parentLoop ;
              }
            }
          }
        }
      }
    }
  }
  if ( result ) {
    System . out . print ( "Yes" ) ;
  }
  else {
    System . out . print ( "No" ) ;
  }
}

public static void main ( String [ ] args ) { int h = 0 ; int w = 0 ; char [ ] [ ] square = null ; String [ ] tmp = null ; try ( BufferedReader br = new BufferedReader ( new InputStreamReader ( System . in ) ) ) { tmp = br . readLine ( ) . split ( " \\ s " ) ; h = Integer . parseInt ( tmp [ 0 ] ) ; w = Integer . parseInt ( tmp [ 1 ] ) ; square = new char [ h ] [ w ] ; for ( int i = 0 ; i < h ; i ++ ) { square [ i ] = br . readLine ( ) . toCharArray ( ) ; } } catch ( IOException e ) { e . printStackTrace ( ) ; System . exit ( 1 ) ; } boolean result = true ; parentLoop : for ( int i = 0 ; i < square . length ; i ++ ) { final char [ ] line = square [ i ] ; for ( int j = 0 ; j < line . length ; j ++ ) { if ( line [ j ] == ' # ' ) { if ( 0 <= i - 1 && square [ i - 1 ] [ j ] != ' # ' ) { if ( i + 1 < h && square [ i + 1 ] [ j ] != ' # ' ) { if ( 0 <= j - 1 && square [ i ] [ j - 1 ] != ' # ' ) { if ( j + 1 < w && square [ i ] [ j + 1 ] != ' # ' ) { result = false ; break parentLoop ; } } } } } } } if ( result ) { System . out . print ( " Yes " ) ; } else { System . out . print ( " No " ) ; } }
(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: (integral_type) declarator: (variable_declarator name: (identifier) value: (decimal_integer_literal))) (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier) value: (decimal_integer_literal))) (local_variable_declaration type: (array_type element: (integral_type) dimensions: (dimensions)) declarator: (variable_declarator name: (identifier) value: (null_literal))) (local_variable_declaration type: (array_type element: (type_identifier) dimensions: (dimensions)) declarator: (variable_declarator name: (identifier) value: (null_literal))) (try_with_resources_statement resources: (resource_specification (resource type: (type_identifier) name: (identifier) value: (object_creation_expression type: (type_identifier) arguments: (argument_list (object_creation_expression type: (type_identifier) arguments: (argument_list (field_access object: (identifier) field: (identifier)))))))) body: (block (expression_statement (assignment_expression left: (identifier) right: (method_invocation object: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list)) name: (identifier) arguments: (argument_list (string_literal))))) (expression_statement (assignment_expression left: (identifier) right: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list (array_access array: (identifier) index: (decimal_integer_literal)))))) (expression_statement (assignment_expression left: (identifier) right: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list (array_access array: (identifier) index: (decimal_integer_literal)))))) (expression_statement (assignment_expression left: (identifier) right: (array_creation_expression type: (integral_type) dimensions: (dimensions_expr (identifier)) dimensions: (dimensions_expr (identifier))))) (for_statement init: (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier) value: (decimal_integer_literal))) condition: (binary_expression left: (identifier) right: (identifier)) update: (update_expression (identifier)) body: (block (expression_statement (assignment_expression left: (array_access array: (identifier) index: (identifier)) right: (method_invocation object: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list)) name: (identifier) arguments: (argument_list))))))) (catch_clause (catch_formal_parameter (catch_type (type_identifier)) name: (identifier)) body: (block (expression_statement (method_invocation object: (identifier) name: (identifier) arguments: (argument_list))) (expression_statement (method_invocation object: (identifier) name: (identifier) arguments: (argument_list (decimal_integer_literal))))))) (local_variable_declaration type: (boolean_type) declarator: (variable_declarator name: (identifier) value: (true))) (labeled_statement (identifier) (for_statement init: (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier) value: (decimal_integer_literal))) condition: (binary_expression left: (identifier) right: (field_access object: (identifier) field: (identifier))) update: (update_expression (identifier)) body: (block (local_variable_declaration (modifiers) type: (array_type element: (integral_type) dimensions: (dimensions)) declarator: (variable_declarator name: (identifier) value: (array_access array: (identifier) index: (identifier)))) (for_statement init: (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier) value: (decimal_integer_literal))) condition: (binary_expression left: (identifier) right: (field_access object: (identifier) field: (identifier))) update: (update_expression (identifier)) body: (block (if_statement condition: (parenthesized_expression (binary_expression left: (array_access array: (identifier) index: (identifier)) right: (character_literal))) consequence: (block (if_statement condition: (parenthesized_expression (binary_expression left: (binary_expression left: (decimal_integer_literal) right: (binary_expression left: (identifier) right: (decimal_integer_literal))) right: (binary_expression left: (array_access array: (array_access array: (identifier) index: (binary_expression left: (identifier) right: (decimal_integer_literal))) index: (identifier)) right: (character_literal)))) consequence: (block (if_statement condition: (parenthesized_expression (binary_expression left: (binary_expression left: (binary_expression left: (identifier) right: (decimal_integer_literal)) right: (identifier)) right: (binary_expression left: (array_access array: (array_access array: (identifier) index: (binary_expression left: (identifier) right: (decimal_integer_literal))) index: (identifier)) right: (character_literal)))) consequence: (block (if_statement condition: (parenthesized_expression (binary_expression left: (binary_expression left: (decimal_integer_literal) right: (binary_expression left: (identifier) right: (decimal_integer_literal))) right: (binary_expression left: (array_access array: (array_access array: (identifier) index: (identifier)) index: (binary_expression left: (identifier) right: (decimal_integer_literal))) right: (character_literal)))) consequence: (block (if_statement condition: (parenthesized_expression (binary_expression left: (binary_expression left: (binary_expression left: (identifier) right: (decimal_integer_literal)) right: (identifier)) right: (binary_expression left: (array_access array: (array_access array: (identifier) index: (identifier)) index: (binary_expression left: (identifier) right: (decimal_integer_literal))) right: (character_literal)))) consequence: (block (expression_statement (assignment_expression left: (identifier) right: (false))) (break_statement (identifier))))))))))))))))) (if_statement condition: (parenthesized_expression (identifier)) consequence: (block (expression_statement (method_invocation object: (field_access object: (identifier) field: (identifier)) name: (identifier) arguments: (argument_list (string_literal))))) alternative: (block (expression_statement (method_invocation object: (field_access object: (identifier) field: (identifier)) name: (identifier) arguments: (argument_list (string_literal))))))))