Plz帮我显示角色。 [英] Plz help me with the characters showing.

查看:73
本文介绍了Plz帮我显示角色。的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

所有

我写一个片段(在VC6.0 PLATFORM中)来显示ASCII字符

范围从0到255.

片段:

#include" stdafx.h"

#include" stdio.h"

#include" conio。 h"

int main(int argc,char * argv [])

{

int i = 0;

for(i = 0; i< 255; i ++)

{

printf("%d =%c \ n",i,i) ;

}

getch();

返回0;

}

IT可以正常显示0-127,但不能显示128-255就像219 =?。

有什么问题?

任何人都可以帮助?

Thx。

----------------- pinkfog ------------ ---

all
I write a snippet(in VC6.0 PLATFORM) to show the ASCII character
ranging from 0-255.
snippet:
#include "stdafx.h"
#include "stdio.h"
#include "conio.h"
int main(int argc, char* argv[])
{
int i = 0;
for(i = 0; i < 255; i++)
{
printf("%d = %c\n", i, i);
}
getch();
return 0;
}
IT can normaly show 0-127,but cannot show 128-255 just like "219=?".
what''s the problem?
Any one can help?
Thx.
-----------------pinkfog---------------

推荐答案

pinkfog opined:
pinkfog opined:
所有
我写了一个片段(在VC6.0 PLATFORM中)来显示ASCII字符
,范围从0到255.
片段:
#include" stdafx.h&q UOT;


不知道这是什么(它不是标准C),但你不需要它

无论如何。 />
#include" stdio.h"


#include< stdio.h>

#include" conio.h"


非标准C.可能也不需要这个。

int main(int argc,char * argv [])
{
int i = 0;


多余的初始化,如下面的初始化。

for(i = 0; i< 255; i ++)
{
printf("%d =%c \ n",i,i);
}
getch();


这是非标准的(来自conio.h)。

标准`getchar()`有什么问题?

返回0;
}

IT可以正常显示0-127,但不能像219 =?那样显示128-255。
有什么问题?
all
I write a snippet(in VC6.0 PLATFORM) to show the ASCII character
ranging from 0-255.
snippet:
#include "stdafx.h"
Don''t know what this is (it''s not Standard C), but you don''t need it
anyway.
#include "stdio.h"
#include <stdio.h>
#include "conio.h"
Not Standard C. Probably don''t need this either.
int main(int argc, char* argv[])
{
int i = 0;
Superfluous inititalisation, as you initialise it below.
for(i = 0; i < 255; i++)
{
printf("%d = %c\n", i, i);
}
getch();
This is non-standard (comes from "conio.h"). What''s wrong with the
standard `getchar()`?
return 0;
}
IT can normaly show 0-127,but cannot show 128-255 just like "219=?".
what''s the problem?




ASCII字符是只有代码为0-127的那些。另一个问题

是在您的控制台设置中。显然它不知道如何显示所有代码(或者你认为它们应该以不同的方式显示)。

不是C问题,所以你可能想问别处。


-

IETF的座右铭是'粗略共识和运行代码''


- Scott Bradner(开源,1999 O'Reilly and Associates)


< http://clc-wiki.net/wiki/Introduction_to_comp.lang.c>



ASCII characters are only the ones with codes 0-127. The other problem
is in the setup of your console. Obviously it does not know how to
display all the codes (or you think they should display differently).
Not a C issue, so you may want to ask elsewhere.

--
"The IETF motto is ''rough consensus and running code''"

-- Scott Bradner (Open Sources, 1999 O''Reilly and Associates)

<http://clc-wiki.net/wiki/Introduction_to_comp.lang.c>


pinkfog写道:
pinkfog wrote:
所有
我写了一个片段(在VC6.0 PLATFORM中)来显示ASCII字符
范围从0到255.
片段:
#include" stdafx.h"
这个标题是什么?

#include" stdio.h"


更喜欢#include< stdio.h>

#include" conio.h"
这个标题是什么?

int main(int argc,char * argv [])
{
int i = 0;
for(i = 0; i< 255; i ++)
{/> printf("%d =%c\ n,i,i);
}
的getch();
为什么?

返回0;
}

IT可以正常显示0-127,但不能像219 =那样显示128-255问题是什么?
任何人都可以提供帮助?
all
I write a snippet(in VC6.0 PLATFORM) to show the ASCII character
ranging from 0-255.
snippet: #include "stdafx.h" What''s this header for?
#include "stdio.h"
prefer #include <stdio.h>
#include "conio.h" What''s this header for?
int main(int argc, char* argv[])
{
int i = 0;
for(i = 0; i < 255; i++)
{
printf("%d = %c\n", i, i);
}
getch(); Why?
return 0;
}
IT can normaly show 0-127,but cannot show 128-255 just like "219=?".
what''s the problem?
Any one can help?




你的语言环境的字符集不包括在内这些角色。


-

Ian Collins。



Your locale''s character set does not include these characters.

--
Ian Collins.


ASCII字符仅来自于0-127。

the ASCII character is only rangin from 0-127.


这篇关于Plz帮我显示角色。的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆