open F, ">file.txt"; while() { print F chr rand( 20 ) + 65; }