#include #define MAXLINE 1000 /* maximum input line length */ /* ggetline: read a line into 'line', return length */ int ggetline(char line[], int maxline){ int c, i; for (i=0; (c=getchar()) != EOF && c!='\n'; ++i){ if (i0){ if (len > max){ max = len; copy(longest, line); } } if (max > 0){ /* there was a line */ printf("%s\n", longest); printf("length: %d\n", max); } return 0; }