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!
Define a complex number in c program:
class complex
{
private:
int real,ima;
public :
void input();
friend complex sum(complex,complex);
void show();
};
void complex:: show(void)
cout << "real part ="<< real << "\nThe imaginary part ="< } void complex ::input() { cout<<"enter the real and imaginary part\n"; cin >> real >> ima; } complex sum( complex a,complex b) { complex c; c.real= a.real + b.real; c.ima= a.ima + b.ima; return c; } void main() { complex a,b,c; clrscr(); a.input(); b.input(); c=sum(a,b); c.show(); getch(); }
}
void complex ::input()
cout<<"enter the real and imaginary part\n";
cin >> real >> ima;
complex sum( complex a,complex b)
complex c;
c.real= a.real + b.real;
c.ima= a.ima + b.ima;
return c;
void main()
complex a,b,c;
clrscr();
a.input();
b.input();
c=sum(a,b);
c.show();
getch();
given integer ''n'' and permutation of numbers 1,2,..n-1, c program to print permutation that lexicograghically precedes given input permutation if permutation is least print input
Q. Explain that how do we implement two stacks in one array A[1..n] in such a way that neither the stack overflows unless the total number of elements in both stacks together is n.
getting a palindrome using minimum replacement
Write a program to find the area under the curve y = f(x) between x = a and x = b, integrate y = f(x) between the limits of a and b. The area under a curve between two points can b
for object, malloc allocates memory in heap however doesn't invoke object's constructor to initialize the object. new allocates memory & also invokes constructor to initialize the
Conversion from Basic to User-Defined variable Consider the following example. class Distance { public :
c programing forcalculating savings of an employee
In POS system, cashier computer connect to printer using serial rs232 usb or cable. We need to capture data from that connection, and parsing the data to get total amount for every
Type Casting Implicit type conversions, as allowed by the language, can lead to errors creeping in the program if care is not taken. Thus, explicit type conversions may be used
application problem of tower of hanoi
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