Johnson & Johnson said it raised the list price of its prescription medicines by an average of 8.5% last year—and 3.5% after discounts—in the health-products company’s first effort to address criticism about the high cost of medicines by opening up about its drug-pricing practices.