sub z{eval"y/$_[0]/$_[1]/";eval"s/$_[1]/$_[2]/;"x pop;$_.$/}$_=' g'x33;print for z(g,b,a,18)x15,z(b,d,c,7)x3,z(a,f,e,14)x4,z(fc,h,g,10),z(dh,i)x9