摘要: #include <stdio.h> int main(void) { int ch; printf("please input an number for char type: "); scanf("%d", &ch); printf("%d is equivalent to %c.\n", ch 阅读全文
posted @ 2021-07-27 23:29 小鲨鱼2018 阅读(26) 评论(0) 推荐(0) 编辑
摘要: 1、 #include <stdio.h> #include <float.h> #include <limits.h> int main(void) { int big_int = 2147483647; float big_float = 3.4E38; float small_float = 阅读全文
posted @ 2021-07-27 23:26 小鲨鱼2018 阅读(42) 评论(0) 推荐(0) 编辑
摘要: 1、c语言中如何处理整数值的上溢。 #include <stdio.h> int main(void) { int i; int j = 1; for(i = 1; i <= sizeof(int) * 8 - 1; i++) { j *= 2; } printf("j = %d.\n", j - 阅读全文
posted @ 2021-07-27 22:36 小鲨鱼2018 阅读(494) 评论(0) 推荐(0) 编辑