switch index with index-4