Saturday 10 April 2021

Function in C and C++ Qus 5

 #include<stdio.h>

#include<conio.h>

#include<iostream.h>

void show(int );

void show(int a,int b);


void show(int x)

{

cout<<x<<endl;

}

void show(int x,int y)    //formal parameter

{

cout<<x+y<endl;

}

int main()

{

clrscr();

show(5);     //actual parameter-calling

show(8,3);


getch();

return 0;

}

No comments:

Post a Comment