write a program to find the largest of two numbers without
using for,while,switch,if else, conditional operator and do
while using c++ pgmng language
Answers were Sorted based on User's Feedback
Answer / random
double largest(double x, double y){
return (x+y)/2. + abs(x-y)/2.;
}
| Is This Answer Correct ? | 28 Yes | 9 No |
Answer / vishal sharma
double largeone(double a,double b)
{
return(((a+b)/2) + ((a-b)/2));
}
| Is This Answer Correct ? | 9 Yes | 2 No |
How do you define a class in oop?
different types of castings
1. Define a class.
what type of questions
any one please tell me the purpose of operator overloading
some one give d clear explanation for polymorphism
Why do we use virtual functions?
#include <iostream> using namespace std; struct wow { int x; }; int main() { wow a; wow *b; a.x = 22; b = &a; a.x = 23; cout << b->x; return 0; }
What is multiple inheritance ?
17 Answers Blue Star, C DAC, CDAC, Impetus, Ness Technologies, Softvision Solution,
Explain virtual inheritance?
What is destructor oops?
write a program which best describes polymorphism in real world?
2 Answers CTS, Infosys, NexGen,