-->
当前位置:首页 > 题库

PROGRAMMING:Positive and negative number

Luz5年前 (2021-05-10)题库540
From the read integer data, count the number of integers greater than zero and the number of integers less than zero. In the program, the number of integers greater than zero is counted by variable I, and the number of integers less than zero is counted by variable J.
###Input format:
In a row, enter n (n < 20) integers separated by spaces, and finally enter 0 to end the input. Only one space can be used between the data.
###Output format:
In the two lines, the output results are in the format of "I = positive number" and "J = negative number", and the number is output as is without column width control.
###Input example:
```in
-8 -9 2 5 -1 -4 0
```
###Output example:
```out
i=2
j=4
```






answer:If there is no answer, please comment