Can someone please help... I'm stuck!!!
I am working on an assignment for my java class, and I am stuck. This is the 1st programming class that i have taken and am a little confused. I am supposed to write a program that inputs 5 numbers and determines and prints the number of negative numbers, positive numbers, and zeros that were inputed.
This is what i have so far:
import java.util.Scanner;
publicclass test
{
publicstaticvoid main (String[] args)
{
Scanner input =new Scanner (System.in);
int number;
int negative = 0;
int positive = 0;
int zero = 0;
int numberCounter = 1;
while (numberCounter <=5)
{
System.out.print("Please enter a number:");
number = input.nextInt();
if (number == 0)
zero = zero +1;
else
negative=negative+1;
numberCounter = numberCounter + 1;
}
System.out.printf(" Positive: %d\n Negative: %d\n Zero: %d\n", positive, negative, zero);
}
}
I don't know how to add another arugment to the if statement for the positive numbers. As of right now, it only correctly adds the zeros and displays the rest as negative numbers. Thank you!

