static int countAlphabets ( int n ) {
  int i , count = 0 ;
  int digits [ ] = new int [ 10 ] ;
  while ( n > 0 ) {
    int digit = n % 10 ;
    digits [ digit ] ++ ;
    n /= 10 ;
  }
  for ( i = 'a' ;
  i <= 'z' ;
  i ++ ) if ( canBePicked ( digits , i ) ) count ++ ;
  for ( i = 'A' ;
  i <= 'Z' ;
  i ++ ) if ( canBePicked ( digits , i ) ) count ++ ;
  return count ;
}

static int countAlphabets ( int n ) { int i , count = 0 ; int digits [ ] = new int [ 10 ] ; while ( n > 0 ) { int digit = n % 10 ; digits [ digit ] ++ ; n /= 10 ; } for ( i = ' a ' ; i <= ' z ' ; i ++ ) if ( canBePicked ( digits , i ) ) count ++ ; for ( i = ' A ' ; i <= ' Z ' ; i ++ ) if ( canBePicked ( digits , i ) ) count ++ ; return count ; }
(method_declaration (modifiers) type: (integral_type) name: (identifier) parameters: (formal_parameters (formal_parameter type: (integral_type) name: (identifier))) body: (block (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier)) declarator: (variable_declarator name: (identifier) value: (decimal_integer_literal))) (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier) dimensions: (dimensions) value: (array_creation_expression type: (integral_type) dimensions: (dimensions_expr (decimal_integer_literal))))) (while_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (decimal_integer_literal))) body: (block (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier) value: (binary_expression left: (identifier) right: (decimal_integer_literal)))) (expression_statement (update_expression (array_access array: (identifier) index: (identifier)))) (expression_statement (assignment_expression left: (identifier) right: (decimal_integer_literal))))) (for_statement init: (assignment_expression left: (identifier) right: (character_literal)) condition: (binary_expression left: (identifier) right: (character_literal)) update: (update_expression (identifier)) body: (if_statement condition: (parenthesized_expression (method_invocation name: (identifier) arguments: (argument_list (identifier) (identifier)))) consequence: (expression_statement (update_expression (identifier))))) (for_statement init: (assignment_expression left: (identifier) right: (character_literal)) condition: (binary_expression left: (identifier) right: (character_literal)) update: (update_expression (identifier)) body: (if_statement condition: (parenthesized_expression (method_invocation name: (identifier) arguments: (argument_list (identifier) (identifier)))) consequence: (expression_statement (update_expression (identifier))))) (return_statement (identifier))))