#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);
    system("pause");

}

C程序设计语言-1-统计行个数


相关文章:

  • 2021-11-21
  • 2021-03-28
  • 2021-11-16
  • 2021-04-11
  • 2022-12-23
  • 2021-10-13
  • 2021-05-09
猜你喜欢
  • 2022-12-23
  • 2021-09-10
  • 2021-07-16
  • 2021-12-17
  • 2021-06-17
  • 2021-08-22
相关资源
相似解决方案