$ar2[0] = $ar1[ $s1[0] ]; $ar2[1] = $ar1[ $s1[1] ];