Topic: 大虾请帮忙:函数预定义的问题

  Print this page

1.大虾请帮忙:函数预定义的问题 Copy to clipboard
Posted by: pursuer2004
Posted on: 2005-08-29 09:45

一个参数的可以,两个参数的怎么定义阿
不好意思,是c程序
sort();//
main()
{
int i,j;
sort(i,j);
}
sort(int i,int j)
{
}
编译的时候出错提示error C2660: 'sort' : function does not take 2 parameters

2.Re:大虾请帮忙:函数预定义的问题 [Re: pursuer2004] Copy to clipboard
Posted by: pursuer2004
Posted on: 2005-08-29 10:19

没有人回答这个简单的c问题吗?

3.Re:大虾请帮忙:函数预定义的问题 [Re: pursuer2004] Copy to clipboard
Posted by: why
Posted on: 2005-08-29 11:01

Be patient!
There is only 34 minutes from 21:45 to 22:19.
Why would you expect someone to "serve" you immediately?
In particular you are asking a C question in a Java forum.

sort(); /* prototype telling the compiler function sort takes no param */

sort(i,j); /* missing prototype for this function */

BTW, that's very very bad C style.


   Powered by Jute Powerful Forum® Version Jute 1.5.6 Ent
Copyright © 2002-2021 Cjsdn Team. All Righits Reserved. 闽ICP备05005120号-1
客服电话 18559299278    客服信箱 714923@qq.com    客服QQ 714923