write a c++ program to find maximum of two numbers using
inline functions.
Answer Posted / manjunathtek
#include<iostream>
using namespace std;
int main()
{
int c;
c=max(5,4); //will display 5
cout<<c<<endl;
return 0;
}
inline int max(int a, int b)
{
return (a>b)? a:b;
}
Is This Answer Correct ? | 140 Yes | 52 No |
Post New Answer View All Answers
What is use of overloading?
Get me an image implementation program.
Why multiple inheritance is not possible?
What is abstraction in oops with example?
Why polymorphism is used in oops?
is there any choice in opting subjects like 4 out of 7
Why do we use class?
write string class as your own class in java without using any built-in function
What is inheritance write a program to show use of inheritance?
How do you answer polymorphism?
What is abstraction in oop?
IS IT NECESSARY TO INITIALIZE VARIABLE? WHAT IF THE INSTANCE VARIABLE IS DECLARED final ? IS IT NECESSARY TO INITIALIZE THE final VARIABLE AT THE TIME OF THEIR DECLARATION?
What is constructor overloading in oop?
What is overloading in oops?
What is polymorphism programming?