#ifndef H_ASPLIT_H #define H_ASPLIT_H enum e_status {ASPLIT_SUCCESS, ASPLIT_INPUT_ERROR, ASPLIT_OUTPUT_A_ERROR, ASPLIT_OUTPUT_B_ERROR}; typedef enum e_status status; /** * Asymmetrically splits file named in_file into 2 files, out_file_a, and * out_file_b, putting num_lines (must be non-negative) lines in the first * file, and the rest in the second file. * * Accepts parameters in_file, for the name of the input file, out_file_a, * for the name of the first output file, out_file_b, for the name of the * second output file, the number of lines to output into the 1st file, * and a pointer to a long int, which will be set to the number of lines * that were output to the 2nd file.Any of the filenames may be "-", * indicating stdin in the case of in_file,or stdout in the case of * out_file_a or out_file_b. * * Returns a status codeindicating success or failure. Possible status * values are given by the e_status enumeration in this header file. * Success is indicated by SUCCESS, and each of the 3 different * failure states is indicated by one of the remaining enum values. * */ int asplit(const char *in_file, const char *out_file_a, const char *out_file_b, const long int num_lines, long int *num_rem_lines); #endif /*H_ASPLIT_H*/