implemented SHIFT operations