Final Prices With a Special Discount in a Shop
Examples
Example 1:
Input: prices = [8, 4, 6, 2, 3]
Output: [4, 2, 4, 2, 3]
Explanation:
Example 2:
Input: prices = [1, 2, 3, 4, 5]
Output: [1, 2, 3, 4, 5]
Explanation:
Example 3:
Input: prices = [10, 1, 1, 6]
Output: [9, 0, 1, 6]