The main 8 part of the "if/else if" have to set the correct value for "carry".
I suggest working on adding without using the input code till you get adding to partly work.
Code:
int arr[5] = {1,0,0,0,0}; // Binary 00001
int arr1[5] = {1,1,0,0,0}; // Binary 00011
Code:
cout<<" arr = "<<arr[4]<<arr[3]<<arr[2]<<arr[1]<<arr[0]<<endl;
cout<<" arr1 = "<<arr1[4]<<arr1[3]<<arr1[2]<<arr1[1]<<arr1[0]<<endl;
Code:
cout<<" sum = "<<sum[5]<<sum[4]<<sum[3]<<sum[2]<<sum[1]<<sum[0]<<endl;
FYI: You last "for" loop is NOT inside the main function; I suugest trying to get code to compile without errors before posting it.
Or, post the errors and warnings if it has them.