用于ASCII控制字符的显式输入/输出IDE中的不同表单

时间:2016-03-31 02:56:51

标签: c ascii

以下程序用于打印ASCII为1到126的字符。

#include <stdio.h>
int main()
{
    int i=1;
    char c=1;
    for(c=1; c<=126; c++)
    {
        printf("%c ",c);
        i++;
        if(i%10==0)
            printf("\n");
    }
    printf("\n");
    return 0;
}

在IDE中运行程序时(vs6.0或codeblocks)。看起来像这样 &#34; result when running in the IDE&#34;

但是当我在IDE中的独立cmd终端中运行它时。它显示不同。请参阅&#34; result when running out the IDE&#34;

0 个答案:

没有答案