Sean Wei
says to
YSITD
s/(...)(.)(..)\2(.)(..)/$1$2$4$3$5