Getting wrong answer in two test cases

Arrays- Sum of two arrays.
Here is the code: https://ide.codingblocks.com/s/114573

Your code is not producing correct output for following case :
4
1 0 2 9
4
9 0 2 9
Output should be : 1, 0, 0, 5, 8, END
Your output : 0, 0, 5, 8, END

Try to modify your code a little bit.

I have made the changes, still getting wrong answer. It is working for this test case:
4
1 0 2 9
4
9 0 2 9

You are not printing the answer in required format for following case :
5
5 4 3 2 1
5
9 8 7 6 5
Expected output :1, 5, 3, 0, 8, 6, END
Your output : 15, 3, 0, 8, 6, END

1 Like

Thanks. All the cases are passed now