2c345e0
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
#include<stdio.h> /* * Count lines in input */ main() { int c, nl; nl = 0; while ((c = getchar()) != EOF) if (c == '\n') ++nl; printf("%d\n", nl); }