A system must operate for t units of time. A certain component is essential for operation of the system and must be replaced by a new component whenever it fails. The price of this component changes over time. The problem of providing the proper number of spares for this component so as to minimize the total expected cost of maintaining the system operative for t units of time is studied. In particular, the authors show that when the component lives are exponentially distributed and the price is strictly increasing, it is optimal to provide n spares when the time remaining until termination is between tn and tnÅ+1, where 0=t0<t1<t2<ëëë. This result is then extended to the case where the price change is arbitrary.