Problem Description
Write a program to find the sum of negative numbers
Input:Positive and negative numbers
Output:Display Sum of negative numbers
Refer sample input and output for formatting specification.CODING ARENA
Test Case 1
Input (stdin)7 10 -10 -43 -45 46 30 31
Expected OutputSum of negative numbers: -98
Test Case 2
Input (stdin)5 10 -10 -43 -45 -46
No comments:
Post a Comment