# Make complex number in C by R4R Team

Complex number:

Example :
2+3i
0+4i
-1-9i
These kind of number are known as complex number.
where 'i' is root -1.

How make complex number ?
We need two thing :
-real part of complex number number
-imaginary part of complex number

Syntax-
a+bi

Where 'a' is the real part.
and 'b' is the imaginary part.

To create a complex number type structure, there are many logic may be possible, one of the way to create a complex number is :

program-

#include< stdio.h>
#include< string.h>
char complex(char r, char im)
{
char s="+";
char i="i";
s='';
i='';
strcat(r,s);
strcat(r,im);
strcat(r,i);
printf("Complex number is %s",r);
}
int main() {
char s1,s2;
printf("Enter real and imaginary part of the complex number\n");
scanf("%s%s",&s1,&s2);
complex(s1,s2);
}

output-

Enter real and imaginary part of the complex number
3
4
Complex number is 3+4i

-In this program, we take an input of real part and imaginary part of the complex number.
-Then pass in function 'complex()', which make complex number in the form of string and display on the screen.
{"ft_lang_label":"__label__en","ft_lang_prob":0.69148433,"math_prob":0.9957023,"size":859,"snap":"2019-35-2019-39","text_gpt3_token_len":261,"char_repetition_ratio":0.21520467,"word_repetition_ratio":0.04477612,"special_character_ratio":0.3329453,"punctuation_ratio":0.17,"nsfw_num_words":0,"has_unicode_error":false,"math_prob_llama3":0.98451126,"pos_list":[0],"im_url_duplicate_count":[null],"WARC_HEADER":"{\"WARC-Type\":\"response\",\"WARC-Date\":\"2019-09-21T19:16:32Z\",\"WARC-Record-ID\":\"<urn:uuid:380d7bae-c975-4127-adab-3de436e0b0a4>\",\"Content-Length\":\"268817\",\"Content-Type\":\"application/http; msgtype=response\",\"WARC-Warcinfo-ID\":\"<urn:uuid:bcf78c28-d2f5-4583-bc71-b5c32296b297>\",\"WARC-Concurrent-To\":\"<urn:uuid:97b57529-7e92-48b8-8b02-7abe4f2cb5e8>\",\"WARC-IP-Address\":\"166.62.27.181\",\"WARC-Target-URI\":\"http://r4r.in/clanguage/topic/post.php?ct=17&subct=141&tp=1488\",\"WARC-Payload-Digest\":\"sha1:HGOSCYKN6EPAAQS7FCECSUXIP74WDZCO\",\"WARC-Block-Digest\":\"sha1:FWKFAGGM57IDPIP2H267LCDEEUWVZKHW\",\"WARC-Identified-Payload-Type\":\"text/html\",\"warc_filename\":\"/cc_download/warc_2019/CC-MAIN-2019-39/CC-MAIN-2019-39_segments_1568514574662.80_warc_CC-MAIN-20190921190812-20190921212812-00278.warc.gz\"}"}