*enter number till user wants and at the end display number of positive, negative and zeroes.

 #include<stdio.h>


void main()
{
    int ipositivenegativezero;
    char ch;
    do
    {
        printf("Enter the number \n");
        scanf("%d", &i);
        if (i>0)
        {
            positive++;
        }
        else if(i<0)
        {
        negative++;
        }
        else
        {
            zero++;
        }
        goto go;
        back:
    } while (1);

    go:
    printf("press y/Y to continue \n"); 
    scanf("%c", &ch);
    if(ch=='Y'||ch=='y')
       goto back;
       

    printf("total positive numbers are %d\n "positive);
    printf("total negative numbers are %d\n "negative);
    printf("total zero numbers are %d\n "zero);
}

Comments