<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def write_packages(self, reqs_file):
 """ Dump the packages in the catalog in a requirements file """

        write_file_lines(reqs_file, ('{}\n'.format(package) for package in self.packages))