corrected stream_merge.cpp