Count Negatives

Easy · rating 800 · Arrays

The first line contains n. The second line has n space-separated integers. Print how many of them are negative.

Constraints: 1 ≤ n ≤ 105

Related problems

Open Count Negatives in Code Arena →