【C语言及程序设计】定义变量 的两种方法

 1 #include "stdafx.h"
 2 #include <stdio.h> 
 3 #define  x 123.456
 4 
 5 int main()
 6 {
 7     int y;
 8     y = x;
 9 
10     printf("%4.2lf\t%d\n", x, y);
11 
12     return 0;
13 }

结果

 

 

 

 

 

=

posted @ 2018-06-01 11:38  Miyazakehime  阅读(412)  评论(0编辑  收藏  举报