The problem of optimal sequential decision for individual sequences, relative to a class of competing o -line reference strategies, is studied for general loss functions with memory. This problem is motivated by applications in which actions may have \long term" e ects, or there is a cost for switching from one action to another. As a rst step, we consider the case in which the reference strategies are taken from a nite set of generic \experts." We then focus on nite-state reference strategies, assuming nite action and observation spaces. We show that key properties that hold for nite-state strategies in the context of memoryless loss functions, do not carry over to the case of loss functions with memory. As a result, an in nite family of randomized nite-state strategies is seen to be the most appropriate reference class for this case, and the problem is basically di erent from its memoryless counterpart. Based on Vovk's exponential weighting technique, in nite-horizon ...