Sum List of Numbers

easy
ArraysAlgorithms

Problem Description

Given a list of integers, calculate and return their sum.

## Problem Statement

Write a program that reads a list of integers from standard input and outputs their sum.

## Input Format

- First line: An integer N, the count of numbers
- Second line: N space-separated integers

## Output Format

- A single integer representing the sum of all numbers

## Example

**Input:**
```
5
1 2 3 4 5
```

**Output:**
```
15
```

Constraints

Constraints:
- 1 <= N <= 10^6
- -10^9 <= each number <= 10^9
- The sum will fit in a 64-bit signed integer

Sample Test Cases

Test Case 1

5
1 2 3 4 5
15

Test Case 2

3
10 20 30
60

Test Case 3

1
42
42

Your Solution

JavaScript
Executing your code against test cases...