If your series prints 10,10,10, it is not shifted. And if it is not shifted, I would assume that it is a shifting problem. Your code above does not shift the series before printing.