Saved Bookmarks
| 1. |
Write a program to input two complex numbers and to find sum of the given complex numbers. |
|
Answer» areal = input("Enter real part of first complex number”) aimg = input("Enter imaginary part of first complex number”) breal = input("Enter real part of second complex number”) bimg = input("Enter imaginary part of second complex number”) totreal = areal + breal totimg = aimg + bimg print “Sum of the complex numbers=",totreal, “+i”, totimg |
|