这是中文版《C程序设计语言》中的一段程序

Posted dsfsf

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了这是中文版《C程序设计语言》中的一段程序相关的知识,希望对你有一定的参考价值。

这是中文版《C程序设计语言》中的一段程序
我在visual studio上面运行之后,只能输入字符,但是打印不出nc的值
请问这是为什么?
#include "stdafx.h"

int main()
{
    long nc;
    nc = 0;
    while (getchar() != EOF)
        ++nc;
    printf("%ld\n", nc);
    return 0;
}http://shijue.me/community/photo-details/7ae9f94ee6834db08016b6e2a60a0317_d
http://shijue.me/community/photo-details/b907c1ed7c714f75bb4cbbc7e2ad16de_d
http://shijue.me/community/photo-details/bc5bf3a6f96749a2b67699538528d97b_d
http://shijue.me/community/photo-details/def65304743241dda9d9fdc6f57fd6ad_d
http://shijue.me/community/photo-details/edee9e8b6e444b3cb6b7cbc6814fbc79_d
http://shijue.me/community/photo-details/7fac47f4ceed44889ca3aac4cfcb8540_d
http://shijue.me/community/photo-details/dacb902a563149c3974bbc8d28ab6499_d
http://shijue.me/community/photo-details/4ec78fcf80ea45528eadf3b2521c4bf5_d
http://shijue.me/community/photo-details/46285442fe8748fba055c47203705435_d
http://shijue.me/community/photo-details/f3f66480e3fa469c8ceabd8ee2ebde89_d
http://shijue.me/community/photo-details/af6cb9178b7d4382a009d582d3bd8c38_d
http://shijue.me/community/photo-details/bf9f8221823f4fad9943024c956c3a64_d
http://shijue.me/community/photo-details/3b87f58430ce41949acd17a51ae38381_d
http://shijue.me/community/photo-details/784ec0bcf4444f0ab6de6e702c0a4f00_d
http://shijue.me/community/photo-details/0162ccac99dc4a3ab0ac857ab81c12f3_d
http://shijue.me/community/photo-details/968572cefc0b46f7bef2c45fb85d43a5_d
http://shijue.me/community/photo-details/e85e6634c0f14855a481304ae56421d5_d
http://shijue.me/community/photo-details/3911d2965bd9411cb342082cf7d7658d_d
http://shijue.me/community/photo-details/02863dee54014617a314fa6602f41d50_d
http://shijue.me/community/photo-details/2c546992d5194eb5ae4d2225243771f0_d
http://shijue.me/community/photo-details/3b4467b0acb24acaa11cfcc52a93d1c1_d
http://shijue.me/community/photo-details/c09c962622e64900bb3df15bf8a4c1d6_d
http://shijue.me/community/photo-details/cc5039a56b2040b587521fd3706f6392_d
http://shijue.me/community/photo-details/2ab2069c1a1c4d4b94d37e8f187ccffa_d
http://shijue.me/community/photo-details/bd6166fed8e54bc28ceeb6ddc94149d9_d
http://shijue.me/community/photo-details/c8eba0d38e7f4266a3b407e5b4a0e0ff_d
http://shijue.me/community/photo-details/bdb4f0c4ceb3499f9c43dd78cc9672f5_d
http://shijue.me/community/photo-details/81e062e8fcf64ea9a294087378b1c868_d
http://shijue.me/community/photo-details/262180fe44fd4d978e1357c5d489afb5_d
http://shijue.me/community/photo-details/ecaf7bc612bb43f1b19ff60c7c56ae51_d
http://shijue.me/community/photo-details/4292e4aaf40a4763b01d7a1e2fdb2b36_d
http://shijue.me/community/photo-details/d32e3ba174f64083938dba90080951a0_d
http://shijue.me/community/photo-details/560fdd64023740568ac966f5a84e9b57_d
http://shijue.me/community/photo-details/5974c0a9d11e4f0fa8697a650aa428a2_d
http://shijue.me/community/photo-details/03c211df1d9841bd974020c40ca3528a_d
http://shijue.me/community/photo-details/c7d24596a86e4518bcb04215abf63d8b_d
http://shijue.me/community/photo-details/f67feec7ba3b4d9fae1be5c40c5dbb01_d
http://shijue.me/community/photo-details/a41b86cf150b45a9aa4df4e346413481_d
http://shijue.me/community/photo-details/6c5903678c4f42e390a255b7731ff3b1_d
http://shijue.me/community/photo-details/f892ccc11dec465c8625a55dc03f32cc_d
http://shijue.me/community/photo-details/e9326d915ad54ec989c84e1f7914f825_d
http://shijue.me/community/photo-details/a0318be577c3414e99f1842cad9c8fc3_d
http://shijue.me/community/photo-details/c7eb11350965414eb1e773079d585e03_d
http://shijue.me/community/photo-details/59e25d5856b2467eab33b9b1f01b6114_d
http://shijue.me/community/photo-details/04256f1be37d4d6f8c2a2ea8629a6d64_d
http://shijue.me/community/photo-details/39d0bd4bddf94cf683007c4c2c0eb35e_d
http://shijue.me/community/photo-details/76b903fa1dce420dade9724d959efc71_d
http://shijue.me/community/photo-details/dd545a30755b4d339f24f8b7683b71d0_d
http://shijue.me/community/photo-details/0b2eec6f4ac04505aa85afd769667748_d
http://shijue.me/community/photo-details/fdafeca1ffa447d5865cf1d0e3b627d7_d
http://shijue.me/community/photo-details/5a829b34cf04499f87da3c6f0b800d38_d
http://shijue.me/community/photo-details/1cb5b53c1ae14785baa80c50b6ca2704_d
http://shijue.me/community/photo-details/f7c472aebe7a49d3a8ff20d60502c763_d
http://shijue.me/community/photo-details/5d46db61922344aba6cf35bcd8160c7e_d
http://shijue.me/community/photo-details/af8e57a45db6477da6c58d76e2c5d51b_d
http://shijue.me/community/photo-details/0cc9b81ff5e4436fb9aa27021aca5a9d_d
http://shijue.me/community/photo-details/04cf280bae12474b878132fa953a3fdf_d
http://shijue.me/community/photo-details/189d13540fd142fbb1e284fb13c1180f_d
http://shijue.me/community/photo-details/832c7b92aa8446c691a71e3dad23d180_d
http://shijue.me/community/photo-details/8236d9dc7bda494185e18a0c111d127b_d
http://shijue.me/community/photo-details/1fd464e52f4e4c1b9bf97e1be46e39c2_d
http://shijue.me/community/photo-details/bc2e635ddbba4bea95986332d7d4516d_d
http://shijue.me/community/photo-details/34cea27d26d44f7580e4ade73f0688b2_d
http://shijue.me/community/photo-details/352cf8d0a8fb4b5683059a9bfba00132_d
http://shijue.me/community/photo-details/a99362dc8ea24a4fa580bf341fc5bb54_d
http://shijue.me/community/photo-details/8961172ad94243c69f5c8337f044cf51_d
http://shijue.me/community/photo-details/ff227abee2374a0f9ad7a4c5e49d3f12_d
http://shijue.me/community/photo-details/0b837f0b28df4b269d45367f6a4df3bc_d
http://shijue.me/community/photo-details/06877f0fa4e04be3839dd3cdca4f7751_d
http://shijue.me/community/photo-details/1ca6a77110d24c20b5cbedf2d3d0c5e5_d
http://shijue.me/community/photo-details/a6102c90f39e4aa7b43c77f030ddb4d7_d
http://shijue.me/community/photo-details/a97639443b1145d883c61e34fd7f4252_d
http://shijue.me/community/photo-details/6daf78c79bcb4282b30e04e9e508c62e_d
http://shijue.me/community/photo-details/a33b112a8e854b1e927fe011b21865d3_d
http://shijue.me/community/photo-details/c492c8c1756645ca9cc89fa4803f89f6_d
http://shijue.me/community/photo-details/55d276b240ec4e7b98643b8b5bd41387_d
http://shijue.me/community/photo-details/9bc00da9f5b549b0bac5107046a320a5_d
http://shijue.me/community/photo-details/ecdb6da58d5d49979c9c2cf514b51594_d
http://shijue.me/community/photo-details/a0079097bf924862969dc4b918c1dcec_d
http://shijue.me/community/photo-details/6240a816ee2a4902b319d3dd5fc4914f_d
http://shijue.me/community/photo-details/6fbf4e33e29845b8ade5e5c8f0f1a44a_d
http://shijue.me/community/photo-details/d36ab3365e9449e494d3cffa1c2313c1_d
http://shijue.me/community/photo-details/c1af5ae2d75148a0a8bc95e04e86690d_d
http://shijue.me/community/photo-details/0514516873dd41c197ebd10c8b3c7d2d_d
http://shijue.me/community/photo-details/851304fbdbf84840b65aece3705bf477_d
http://shijue.me/community/photo-details/1d40bac78a4a4f9fa4b57490a09de30b_d
http://shijue.me/community/photo-details/6f274e34f074483484162a2a9a58337e_d
http://shijue.me/community/photo-details/af3b4cfc96ac4f6b939c2d7da62f28c4_d
http://shijue.me/community/photo-details/8caa298ae9e941db9e1087970506db3b_d
http://shijue.me/community/photo-details/c1284bef3d754c1bbd73a49b0e67e559_d
http://shijue.me/community/photo-details/152d7b1909d04df497865223d12d9d9c_d
http://shijue.me/community/photo-details/5d53bebdab3b4dc9a16fd46749b2cab2_d
http://shijue.me/community/photo-details/a6f22beb2b3b4181a728777941fe7e46_d

以上是关于这是中文版《C程序设计语言》中的一段程序的主要内容,如果未能解决你的问题,请参考以下文章

求大神,c语言大神,一段程序说的啥意思,全局变量等于0怎么循环下面的

求一段C语言程序,主要是比较两个数据组。

c语言函数。

C语言 编写一个程序 能够统计一段文字里相同字符串的个数

大牛带你学 | C语言的指针及相关运算符总体归纳

1. 用C语言写一段程序:从键盘上输入两数,判断其大小关系,将判断结果显示在屏幕上。