Without using the complex.h header file, suppose I want to create my own header file where I will define a variable argument function,
- taking value 0 if I did not insert any value from the keyboard,
- becoming a real number if I input only one value,
- and a complex number if I input two values.
How can such a complex number be implemented? I have been thinking about the "i" symbol for the imaginary part. How can it appear? Is there any nice way to write a complex number?
Also I need to define addition in the complex field. How can that be done?