Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

How to write in a function declaration and in function call in
which the function has 'n' number of varible or arguments?

Answer Posted / aravind

#include<stdio.h>
int example(int );/*function prototype*/
int main()
{
int a[4]={1,2,3,4,5},i;
example(a[0]);/*function call*/
printf("a=%d",a[i]);
}
int example(int b[k])/*function defintion*/
{
int j;
for(j=0;j<=4;j++)
printf("%d",b[j]);
}
/*here i took n=4*/

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How do you list a file’s date and time?

1108


Do variables need to be initialized?

1109


What is function in c with example?

1229


How many types of arrays are there in c?

1083


Write a program for finding factorial of a number.

1140


How can I open files mentioned on the command line, and parse option flags?

1104


How can I sort a linked list?

1081


What does static variable mean in c?

1139


`write a program to display the recomended action depends on a color of trafic light using nested if statments

2176


What is difference between union and structure in c?

1241


Why does notstrcat(string, "!");Work?

1204


What is the difference between malloc calloc and realloc in c?

1187


Write a program to reverse a given number in c?

1077


What are Macros? What are its advantages and disadvantages?

1216


given post order,in order construct the corresponding binary tree

2854