p_slice function

Slice operations