Already have an account? Get multiple benefits of using own account!
Login in your account..!
Remember me
Don't have an account? Create your account in less than a minutes,
Forgot password? how can I recover my password now!
Enter right registered email to receive password!
Create Complex number using constructor:
class complex
{
private:
int real,ima;
static int count;
public :
complex (int a,int b) //constructor
real=a;
ima=b;
}
complex() //default constructor
real=0;
ima=0;
void show()
cout<< real<<"\n"< } friend complex sum(complex ,complex); ~complex () // destructor { } }; int complex :: count=15; complex sum( complex a,complex b) { complex c3; c3.real= a.real + b.real; c3.ima= a.ima + b.ima; return c3; } void main() { complex a,b,c; clrscr(); a = complex(10,12); //constructor b= complex(12,10); c=sum(a,b); c.show(); //cout < getch(); }
friend complex sum(complex ,complex);
~complex () // destructor
};
int complex :: count=15;
complex sum( complex a,complex b)
complex c3;
c3.real= a.real + b.real;
c3.ima= a.ima + b.ima;
return c3;
void main()
complex a,b,c;
clrscr();
a = complex(10,12); //constructor
b= complex(12,10);
c=sum(a,b);
c.show();
//cout < getch(); }
getch();
Write a program to find minimum number of shelves
Create an array of Strings and fill it with some interesting text, such as vacation destinations, album names, or weapon names from a CRPG. Display three elements of the array on t
Program is to display the contents of file on a screen: Write a program to display the contents of file on a screen void main() { clrscr(); ifstream fin("ascii
Hi, I am looking for a tool that can do token count
Ask4. Write a query to display the columns listed below. The query should list each customer in which the video rental is overdue. The Days_Overdue column should calculate the numb
Smugglers are becoming very smart day by day. Now they have developed a new technique of sending their messages from one smuggler to another. In their new technology, they are send
Write a program that displays both the lower case and upper case alphabetical letters using the following Format Lowercase Uppercase a A
What is the difference between an external iterator and an internal iterator? Ans) An internal iterator is executed with member functions of the class that has items to step th
Write a C program to input your full forename and full surname. e.g James McCarren and display in one string your complete initial and surname i.e J McCarren . Your initial should
what is the function of spanning tree in graph algorithm?
Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!
whatsapp: +91-977-207-8620
Phone: +91-977-207-8620
Email: [email protected]
All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd