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...

C passes By value or By reference?

Answer Posted / ravi chandra

pass by value means passing values to the function
values means numericals
and pass by reference means passing addresses of the values..
fun(int a ,int b ) //pass by value

fun(int *a,int *b)// pass by reference



pass by reference

fun(int &a,int &b)
{
}
fun(int *c,int *d) // *c=*(&a) ,*d=*(&b)

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Is c language still used?

932


How does #define work?

1011


Is main an identifier in c?

1086


Why is c still so popular?

1005


What is the purpose of ftell?

1033


What is the difference between procedural and functional programming?

1008


what is the difference between 123 and 0123 in c?

1156


What is a double c?

941


a parameter passed between a calling program and a called program a) variable b) constant c) argument d) all of the above

1069


Explain what is the purpose of "extern" keyword in a function declaration?

1028


write a c program to find the sum of five entered numbers using an array named number

2076


Can we access array using pointer in c language?

1040


How can I manipulate strings of multibyte characters?

1076


Write a progarm to find the length of string using switch case?

2025


What is assert and when would I use it?

963