+ 1

What is argument (passing argument) , parameters, ? Please tell me . ( If possible with example. )

Note: sometime i ask questions like foolish, but i don't know that.

28th Dec 2020, 6:58 PM
SARVESH ASHOK DEVRUKHAKAR
SARVESH ASHOK DEVRUKHAKAR - avatar
4 Answers
+ 2
Some functions need input like function add to added two numbers so in function definition you write int add(int a,int b); Here a and b are called params.But when called inside main function they are called arguments or the real value of numbers a and b : add(5,6); So 5 and 6 are called arguments.
28th Dec 2020, 7:12 PM
HBhZ_C
HBhZ_C - avatar
+ 2
When function is defined may be it has or not parameters.params are passed in function definition outside main function.Vs arguments which are required in function call or execution in the main function.
28th Dec 2020, 7:03 PM
HBhZ_C
HBhZ_C - avatar
+ 2
HBhZ_C , excellent! Thank you.
28th Dec 2020, 7:14 PM
SARVESH ASHOK DEVRUKHAKAR
SARVESH ASHOK DEVRUKHAKAR - avatar
+ 1
Can you tell ME more clear?
28th Dec 2020, 7:08 PM
SARVESH ASHOK DEVRUKHAKAR
SARVESH ASHOK DEVRUKHAKAR - avatar