edited input_count