Monday 26 April 2021

Function Parameter Matching and Overloading Qus - 3

 #include<iostream.h>

#include<conio.h>

void show(float a)

{

cout<<"float - "<<a<<endl;

}

int main()

{

clrscr();

show(5);     //conversion

show('k');  //conversion

show(6.7);  //Exact Match

//show();      //No Match - Error

getch();

return 0;


}

No comments:

Post a Comment