English Deutsch Français Italiano Español Português 繁體中文 Bahasa Indonesia Tiếng Việt ภาษาไทย
All categories

Hi could u pls type me a prog for polynomial addition in C++???
using operator overloading(+)..Thanks...

2006-12-12 01:04:57 · 5 answers · asked by savi 3 in Computers & Internet Programming & Design

5 answers

I would like to help

BUT

BETTER DO YOUR ASSIGNMENT YOURSELF

2006-12-14 08:32:58 · answer #1 · answered by A Friend of Yours 2 · 0 0

i have continually had good luck with it. you want to comprehend the cycle of the flea. in case you deal with your canine and it wears off using being over a month because you treated it does no longer recommend that your canine doesn't have flea eggs or larva on him. So he has eggs on him that take a lengthy time period to hatch and turn into complete blown fleas. in case you stay in a community the position it truly isn't any longer reliable frozen outdoors for various months, fleas isn't completely die. in the different case its continually flea season. how you are able to deal with your canine is to apply Frontline or maybe with that you choose that's larger high quality like Frontline and to adhere to each and each and every 28 days. they say they artwork nicely for 30 days. That way they're coated and there isn't any longer a lapse at the same time as they don't look to be coated good.

2016-11-25 22:36:26 · answer #2 · answered by wiltshire 4 · 0 0

#include
class poly
{
int a,b,c;
public:
void getdata()
{
cout<<"\n Enter the square term coefficient :";
cin>>a;
cout<<"\n Enter the linear (x) term coefficient :";
cin>>b;
cout<<"\n Enter the constant term:";
cin>>c;
}
void putdata()
{
cout< }
poly operator +(poly ob2)
{
poly res;
res.a =ob2.a+a;
res.b=ob2.b+b;
return(res);
}
};
void main()
{
poly ob1,ob2,ob3;
cout<<"\n Enter first polynomial :";
ob1.getdata();
cout<<"\n ENter the second polynomial:";
ob2.getdata();
ob3=ob1+ob2;
ob3.putdata();
}

2006-12-13 03:29:39 · answer #3 · answered by twinky 2 · 0 0

create two arrays for coefficients of each polynomial.
use for for a loop of coefficients such as
n=4;
for(int i=0;i a[i]=a[i]+b[i];
printf("%d. coefficient = %d",i,a[i]);
}


N.B.:
use cout command instead of printf

2006-12-12 01:15:25 · answer #4 · answered by iyiogrenci 6 · 0 0

www.cprogramming.com

2006-12-12 03:28:34 · answer #5 · answered by chinmay 2 · 0 0

fedest.com, questions and answers