Current location - Plastic Surgery and Aesthetics Network - Plastic surgery and medical aesthetics - How does C judge that an array is all greater than 0?
How does C judge that an array is all greater than 0?
Find the length of the integer array first, define an identifier, change the value of this identifier if it is less than 0 when traversing the array, and judge after traversing. If there is no change, prove that all the numbers in the array are greater than 0.

When writing a program, you should have an idea first, and don't type all the code at once. After clearing your mind first, the rest is to translate your ideas into C language.