从字符值转换为ASCII数字 [英] convert from character value to ASCII number
本文介绍了从字符值转换为ASCII数字的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我需要一个代码,当我输入一个字符时,程序将打印相同字符的ASCII数字??
i need code that when i input a character the program will print the ASCII number of same character ??
推荐答案
int i = getchar();
printf("%d", i);
这篇关于从字符值转换为ASCII数字的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文