| 网站首页 | 业界新闻 | 小组 | 威客 | 人才 | 下载频道 | 博客 | 代码贴 | 在线编程 | 编程论坛
欢迎加入我们,一同切磋技术
用户名:   
 
密 码:  
共有 769 人关注过本帖
标题:[原创]
只看楼主 加入收藏
sunset
Rank: 1
等 级:新手上路
帖 子:14
专家分:0
注 册:2005-4-16
收藏
 问题点数:0 回复次数:10 
[原创]
“编写一函数对从主函数中传递过来的三个数,从中选出最大数和最小数,并通过形参传回主函数。”可以帮我吗?
搜索更多相关主题的帖子: 函数 
2005-05-24 11:04
Rank: 1
等 级:新手上路
帖 子:255
专家分:0
注 册:2005-4-25
收藏
得分:0 
又是找人做作业的啊

/bbs/showimg.asp?BoardID=5&filename=2005-4/2005427111228529.jpg" border="0" onload="if(this.width>screen.width*0.7) {this.resized=true; this.width=screen.width*0.7; this.alt='Click here to open new window\nCTRL+Mouse wheel to zoom in/out';}" onmouseover="if(this.width>screen.width*0.7) {this.resized=true; this.width=screen.width*0.7; this.style.cursor='hand'; this.alt='Click here to open new window\nCTRL+Mouse wheel to zoom in/out';}" onclick="if(!this.resized) {return true;} else {window.open('http://bbs./bbs/showimg.asp?BoardID=5&filename=2005-4/2005427111228529.jpg');}" onmousewheel="return imgzoom(this);" alt="" /> 欢迎加入C语言QQ群698156 我们都是菜鸟乃至新手 坚信有一天定能展翅高飞 因为有着努力的决心 衷心盼望你的到来 让我们一起进步
2005-05-24 18:27
Rank: 1
等 级:新手上路
帖 子:255
专家分:0
注 册:2005-4-25
收藏
得分:0 
见这人问过好多了 自己却没发表过感想

/bbs/showimg.asp?BoardID=5&filename=2005-4/2005427111228529.jpg" border="0" onload="if(this.width>screen.width*0.7) {this.resized=true; this.width=screen.width*0.7; this.alt='Click here to open new window\nCTRL+Mouse wheel to zoom in/out';}" onmouseover="if(this.width>screen.width*0.7) {this.resized=true; this.width=screen.width*0.7; this.style.cursor='hand'; this.alt='Click here to open new window\nCTRL+Mouse wheel to zoom in/out';}" onclick="if(!this.resized) {return true;} else {window.open('http://bbs./bbs/showimg.asp?BoardID=5&filename=2005-4/2005427111228529.jpg');}" onmousewheel="return imgzoom(this);" alt="" /> 欢迎加入C语言QQ群698156 我们都是菜鸟乃至新手 坚信有一天定能展翅高飞 因为有着努力的决心 衷心盼望你的到来 让我们一起进步
2005-05-24 18:28
sunset
Rank: 1
等 级:新手上路
帖 子:14
专家分:0
注 册:2005-4-16
收藏
得分:0 
我不是不想发表感想,因为这是我不会的题。我们发了很多很多的题,自己做会的,可是不会的身边有没有人教,只有上网问你们了。毕竟人多力量大吗?不是吗?如果是单纯的应付作业,我还不如抄别人的呢?干吗上网花钱问你们?
2005-05-26 16:20
tary
Rank: 1
等 级:新手上路
帖 子:780
专家分:0
注 册:2004-10-5
收藏
得分:0 

int change(int a,int b,int c,int flag) {int max,min,k,t; if(flag==1) {k=b>c?b:c; max=a>k?a:k; return max; } else if(flag==0) {t=b<c?b:c; min=a<t?a:t; return min; } } main() { int m,n,l,min,max; printf("please input the number of the m,n,l:\n"); scanf("%d %d %d",&m,&n,&l); max=change(m,n,l,1); min=change(m,n,l,0); printf("%-2d %d",max,min); getch(); }

偶帮你写了个, 你看看吧....




┌→¨ ≮我可以学会对你很冷落≯¨←┐ │  <却学不╓══╦══╖会将爱> │ │¨←┐ ╭╩╮哭‖哭╭╩╮ ┌→¨│ └──┘收 ╲╱ ◇‖◇ ╲╱回└──┘
2005-05-26 17:08
牛虻
Rank: 1
等 级:新手上路
威 望:1
帖 子:472
专家分:0
注 册:2004-10-1
收藏
得分:0 
输出最大值  c:d?c&gt;d=a:b?a&gt;b
输出最小值  c:d?c&lt;d=a:b?a&lt;b

土冒
2005-05-26 22:52
tary
Rank: 1
等 级:新手上路
帖 子:780
专家分:0
注 册:2004-10-5
收藏
得分:0 
告诉个坏消息, 那样不行..

┌→¨ ≮我可以学会对你很冷落≯¨←┐ │  <却学不╓══╦══╖会将爱> │ │¨←┐ ╭╩╮哭‖哭╭╩╮ ┌→¨│ └──┘收 ╲╱ ◇‖◇ ╲╱回└──┘
2005-05-26 23:20
疯狂魔神
Rank: 1
等 级:新手上路
帖 子:22
专家分:0
注 册:2005-4-2
收藏
得分:0 
告诉楼上个不幸的消息,我不能理解,能给我解释下通过形参传回的意思吗?

对我的帮助我记在心里 对我的取笑我看在眼中 比菜,我说了算 我努力在学~
2005-05-26 23:46
tary
Rank: 1
等 级:新手上路
帖 子:780
专家分:0
注 册:2004-10-5
收藏
得分:0 

┌→¨ ≮我可以学会对你很冷落≯¨←┐ │  <却学不╓══╦══╖会将爱> │ │¨←┐ ╭╩╮哭‖哭╭╩╮ ┌→¨│ └──┘收 ╲╱ ◇‖◇ ╲╱回└──┘
2005-05-27 12:33
ChenMo
Rank: 16Rank: 16Rank: 16Rank: 16
等 级:版主
威 望:3
帖 子:481
专家分:10
注 册:2004-4-8
收藏
得分:0 
所谓的“通过形参传回”是利用形参做返回变量的意思么?

返回是一次性返回,还是一次只返回两者之一?

参数类型呢?

欢迎加入 MVC 技术讨论群(新群:90093426)
2005-05-27 13:22
快速回复:[原创]
数据加载中...
 
   



关于我们 | 广告合作 | 编程中国 | 清除Cookies | TOP | 手机版

编程中国 版权所有,并保留所有权利。
Powered by Discuz, Processed in 0.020762 second(s), 7 queries.
Copyright©2004-2024, BCCN.NET, All Rights Reserved