1. A method for programming a phase-change memory cell having s> 2 programmable cell states, the method comprising: applying at least one control signal to produce a programming pulse for programming the cell; and varying at least one control signal during the programming pulse to shape the programming pulse in dependence on the cell state to be programmed and produce a selected one of a plurality of programming pulse waveforms corresponding to respective programming trajectories for programming the cell states; wherein the selected programming pulse waveform corresponds to a programming trajectory containing the cell state to be programmed.