search 登录 注册
arrow_back返回列表
ID:45678
light_modedark_modestar
Lv.6 胸怀六国志
edit_note帖子 199
stars积分 740,884
event加入 2011-05-28
休闲灌水

c计算圆的周长和面积。

schedule发表于 2011-10-31 18:09:00 visibility查看 343 chat_bubble回复 2
#1 楼主
#define PI 3.14159
main()
{
int r=6;float l,s;
i=2*PI*r;s=PI*r*r;
printf(“r=%d,l=%f,s=%f\n“,r,l,s);
}运行结果为r=6,i=37.69908,l=133.097237。

全部回复 (2)

ID:58829
light_modedark_modestar
Lv.1 韶华一笑间
2011-10-31 18:14:00 沙发
怎么那么…
ID:10086
light_modedark_modedark_modestarstar
Lv.2 独赏二月雪
2011-10-31 19:21:00 板凳
不懂也
登录 后才能回复