due to size_t output.txt file becomes greater than we need