![](https://img-blog.csdnimg.cn/20201014180756916.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
C Language
文章平均质量分 77
sun_kang
这个作者很懒,什么都没留下…
展开
-
C 数据类型
C语言有五种基本数据类型:字符、整型、单精度实型、双精度实型和空类型。尽管这几种类型数据的长度和范围随处理器的类型和C语言编译程序的实现而异,但以b i t为例,整数与CPU字长相等,一个字符通常为一个字节,浮点值的确切格式则根据实现而定。对于多数微机,表2 - 1给出了五种数据的长度和范围。 表中的长度和范围的取值是假定C P U的字长为1 6 b i t。C语言还提供了几种聚合类型(aggre原创 2006-09-30 10:54:00 · 1073 阅读 · 0 评论 -
C浮点数据格式[转]
#include int main(int argc, char *argv[]){ float p = 5.1f; int f = (int)(p*100); printf("%d", f); getch( ); return 0;}我想要输出 510,可是机器nnd居然输出509(竟然敢扣我工钱)。到底是whats wrong。我上看下看,左看又看,看了转载 2006-09-30 09:42:00 · 1954 阅读 · 1 评论 -
[zz]C talk
Array & Pointer Are they equivalent?Consider the following two pieces of code:int *p;...c = p[1];int p[10];...c = p[1];Are they equivalent? If not, which is fast转载 2008-04-16 22:05:00 · 1340 阅读 · 0 评论