CoolInterview.com - World's Largest Collection of Interview Questions & Answers, FAQs, queries, sample papers, exam papers, dumps, what, why, how, where, when questions
Interview Success Kit - 9,000 Interview Que. & Ans.
Covers 9,000+ Interview Questions asked in actual MNC Interviews - all with model answers.
Get Your Dream Job Now - www.vyoms.com
Sponsored Links
Interview Questions
Our Services

INTERVIEW QUESTIONS C FUNCTIONS IN C DETAILS
Question :
What is an argument ? differentiate between formal arguments and actual arguments?
Category Functions in C Interview Questions
Rating (3.3) By 23 users
Added on 10/22/2009
Views 5091
Rate it!
Answers:

An argument is an entity used to pass the data from calling function to the called function. Formal arguments are the arguments available in the function definition.They are preceded by their own data types.Actual arguments are available in the function call.



arguments are called as parameters .they are
passed from main function to sub function.

formal arguments are located in sub function.
actual arguments are located in function
the values of actual arguments
are copied to formal arguments.



Posted by: raja

Contact raja Contact raja

The arguments listed in function definition are known as formal arguments. And the arguments passed to function while invoking it, are known as actual arguments.

For e.g:
-----------
int foo(int a, int b)
{
return (a+b);
}

int main(void)
{
int var1 = 10, var2 = 10;
int result;
result = foo(var1, var2);
return 0;
}

in the above case, var1 & var2 are actual arguments and "a" and "b" are formal arguments.



Posted by: Ravi A Joshi

Contact Ravi A Joshi Contact Ravi A Joshi

Argument is a parameter which is used to pass into function during function call

Actual argument is a parameter which is available in calling function

Formal argument is a parameter which is available in called function/function definition

Both actual and formal argument must be same which is declared before main

VENKATGOPU



Posted by: VENKATGOPU

Contact VENKATGOPU Contact VENKATGOPU

If you have the better answer, then send it to us. We will display your answer after the approval.
Rules to Post Answers in CoolInterview.com:-

  • There should not be any Spelling Mistakes.
  • There should not be any Gramatical Errors.
  • Answers must not contain any bad words.
  • Answers should not be the repeat of same answer, already approved.
  • Answer should be complete in itself.
  • Name :*
    Email Id :*
    Answer :*
    Verification Code Code Image - Please contact webmaster if you have problems seeing this image code Not readable? Load New Code
    Process Verification Enter the above shown code: *
    Inform me about updated answers to this question

    Related Questions
    View Answer
    What is the purpose of main( ) function?
    View Answer
    What are the advantages of the functions?
    View Answer
    What is a method?
    View Answer

    Please Note: We keep on updating better answers to this site. In case you are looking for Jobs, Pls Click Here Vyoms.com - Best Freshers & Experienced Jobs Website.

    View ALL Functions in C Interview Questions & Answers

    User Options
    Latest 20 Questions
    What are monomorphic and polymorphic classes?
    Why is Standard Template Library used?
    How should runtime errors be handled in C++?
    What do you mean by internal linking and external linking in c++?
    What is implicit conversion/coercion in c++?
    What is difference between shallow copy and deep copy? Which is default?
    What is virtual destructors? Why they are used?
    What do you mean by C++ access specifiers ?
    What are the advantages of operator overloading?
    What are the advantages of using cin and cout compared to scanf(...) and printf(...), respectively?
    What are static members and static functions?
    What are storage qualifiers in C++ ?
    What is the use of default constructor?
    What are tokens in C++?
    Define destuctors ?
    What is the difference between a template class and class template?
    What are the differences between new and malloc ?
    What is difference between template and macro ?
    What do you mean by early binding?
    How can we access protected and private members of a class?


    Copyright ©2003-2016 CoolInterview.com, All Rights Reserved.
    Privacy Policy | Terms and Conditions

    Download Yahoo Messenger | Placement Papers| FREE SMS | ASP .Net Tutorial | Web Hosting | Dedicated Servers | C Interview Questions & Answers

    Testing Articles | Testing Books | Testing Certifications | Testing FAQs | Testing Downloads | Testing Interview Questions | Testing Jobs | Testing Training Institutes


    Cache = 0.611328 Seconds