Skip to main content

Argument vs Parameter


For your knowledge, let me tell you these two terms argument and parameter are not same.

Trick1

parameter

In a function definition, a parameter is a variable


         void introduction(string name, int age){
         // Here name and age are parameters of the introduction function
         out << "Hello! My name is Manoj Kumar">
         }
         

argument

When a function is called, an argument is passed as a value.


         int main() {
         // Here Jerry and 15 are arguments passed to the introduction function 
         introduction("Jerry", 15);
         return 0;
         }
         

Add new comment

Restricted HTML

  • You can use shortcode for block builder module. You can visit admin/structure/gavias_blockbuilder and get shortcode, sample [gbb name="page_home_1"].
  • You can use shortcode for block builder module. You can visit admin/structure/gavias_blockbuilder and get shortcode, sample [gbb name="page_home_1"].