Skip to main content
To Get All Information of Sarkari Jobs | Results | Admit Card | And courses ,Internships then CLICK HERE

Actual Argument And Formal Argument-:


  • Actual argument/Actual Parameter are those argument whose value are transferred to the function at the time of its calling and actual argument may be constant,variable or an expression.
  • Formal Argument /Formal Parameter are those argument which receives the value of actual argument.
  • The data type,order,counting of actual and formal argument should match existingly.

techprogramiz
img credit: Google images

Example-:
#include<stdio.h>
#include<conio.h>
int sum_value(int,int)
main()
{int a=0,b=0,s=0;
printf("Enter The Value Of a And b \n ");
scanf("%d %d",&a,&b);
s=sum_value(a,b);            /* Actual Argument */
printf("%d sum=%d",s);
getch();
}
int sum_value(int a,int b)    /* Formal Argument */
{s=0;
  s=a+b;
  return s;
}

Output-:
Enter The Value Of a And b 10
5
sum=15

Comments

Post a Comment

Please do not enter any spam link in the comment box.


Download The Book "Let Us C" By Yashavant P.Kanetkar,Click The Below Button

-->Email Subscription

Enter Your Email Address:-

Delivered by FeedBurner

Copyright © 2020 TechProgramiz|All Right Reserved|Made By-: Sudarshan Pandey