Dynamic programming has been used to solve numerous complex problems in business and engineering. This study applies dynamic programming to a retail decision-making problem related to trade credit. A price, shelf-space, and time-dependent demand function is introduced to model the finite time horizon inventory. Trade credit was considered in the model because suppliers commonly provide retailers with credit periods. Consequently, the retailer is not required to pay for goods immediately upon receipt, and can instead earn interest on the retail price of the goods between the time the goods are sold and the end of the credit period. The objective of this paper is to determine the periodic retail price, shelf-space quantity, and ordering quantity that maximize total profit. The numerical examples explain the procedures of the solution approach and show that dynamic decision making is superior to fixed decision making regarding profit maximization.