So you're reading through K&R's The C Programming Language
, and you're on page 29 or so, section 1.9 entitled Character Arrays
The beginning of the sample program is as follows:
#define MAXLINE 1000 /* maximum input line size */
int getline(char line, int maxline);
void copy(char to, char from);
/* print longest input line */
And, to your confusion, you receive the following error: Error: conflicting types for 'getline'
It turns out getline is included in stdio.h, similar to printf! You can complete the exercise by renaming the getline function to something different like "readline" or "get_the_line".
March 10, 2012