Thread Closed  Post Thread 

Question in C
Author Message
kateriyan
Junior Member



Posts: 3
Group: Registered
   
Cash: 0.00 Donate
Question in C

Hello,

"Can there be at least some solution to determine the number of arguments passed to a variable argument list function?"
I am really confuse about that..Please suggest me the proper way..
Thank you in advance..


buy nintendo dsi r4
01-19-2010 02:36 PM
Send the author a private message Find all posts by this author Quote this message in a reply
Affiliate Banner
This is an ad revenue sharing forum
Nameslot
Administrator

Administrators

Posts: 1,767
Group: Administrators
   
Cash: 100.50 Donate
RE: Question in C

Variable argument list can have unlimited number of arguments passed to it.

So you cannot determine in advance. But yes you can determine the arguments once they are passed, by counting it with some incremental variable to count the arguments that were passed to it.

Thanks.


Sponsor Ads | Nameslot.com
01-19-2010 03:55 PM
Send the author an email Send the author a private message Visit authors website Find all posts by this author Quote this message in a reply
cigarboy
Junior Member



Posts: 3
Group: Registered
   
Cash: 0.00 Donate
RE: Question in C

If all variable have same type use and array, and you can put how many variables you want


Welcome to my world cuban cigars
01-30-2010 09:17 PM
Send the author a private message Find all posts by this author Quote this message in a reply
tufni
Junior Member



Posts: 3
Group: Registered
   
Cash: 0.00 Donate
RE: Question in C

you can define number of variable in argument. But the better thing is can't define argument in advance, define as per requirement of your program.

12-25-2010 07:43 AM
Send the author a private message Find all posts by this author Quote this message in a reply
MichelBachkhem
Junior Member



Posts: 11
Group: Registered
   
Cash: 0.00 Donate
RE: Question in C

The no. of arguments is a variable and cannot be known but there's always a limit which only the manufacturer of the compiler knows.


VPS Hosting India
12-28-2010 07:38 PM
Send the author a private message Find all posts by this author Quote this message in a reply
johnpitter
Junior Member



Posts: 12
Group: Registered
   
Cash: 0.00 Donate
RE:  Question in C

Nameslot Wrote:

Variable argument list can have unlimited number of arguments passed to it.

So you cannot determine in advance. But yes you can determine the arguments once they are passed, by counting it with some incremental variable to count the arguments that were passed to it.

Thanks.




I agree with you. You can pass number of argument.


Rx software|appointment booking software
02-03-2011 02:57 PM
Send the author a private message Find all posts by this author Quote this message in a reply

Thread Closed  Post Thread 


View a Printable Version | Send this Thread to a Friend | Subscribe to this Thread | Add Thread to Favorites
Rate This Thread:
Forum Jump: