open(FILE, 'D:\Versuch\demo2.dat'); map { s/x/Y/ig } (@tmp = ); open(FILE, '>D:\Versuch\demo2.dat'); print FILE for @tnp;