码迷,mamicode.com
首页 > 其他好文 > 详细

单分支和双分支选择结构程序设计

时间:2017-02-14 20:42:07      阅读:418      评论:0      收藏:0      [点我收藏+]

标签:结构   程序   nbsp   can   etc   int   put   scanf   设计   

#include<stdio.h>

void main()

{

     int  iX,iY;

  printf("please intput a integer:");

scanf("%d",&iX);

iY=iX;

if(iX<0)

iY=-iX;

printf("\n|%d|=%d",iX,iY);

getch();

}

单分支和双分支选择结构程序设计

标签:结构   程序   nbsp   can   etc   int   put   scanf   设计   

原文地址:http://www.cnblogs.com/KLDYG/p/6399082.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!