Improved algorithms for data manipulations in Stream\[Reader,Writer]