#include <stdio.h>
int main()
{
    int numArrays[] = {2, 67, 23, 5, 7, 34, 14, 4, 8, 62};
    int i;

    printf("Odd Numbers in numArray:\n");

    for(i=0;i<10; i++)
    {       
       if(numArray[i]%2==1)
       {
        printf("%d ",numArray[i]);
    total += i;
        sum=sum+total;
    sum=sum+1;
    printf("There are %d odd numbers\n", sum);
       }        
     }

    printf("even numbers in numArray;\n");
     for(i=0; i<10; i++)
        {
         if(numArray[i]%2==0)
            {
                printf("%d", numArray[a]);
        total += i;
            sum=sum+total;
        sum=sum+1;
        printf("There are %d odd numbers\n", sum);
         }
    }
}

whats the problem of this code? im just a biggener ...hehehe

what does it do or what does it not do that you want it to do? We need a bit more information about that the problem is. I can tell you that you don't need line 29.

Please don't create new threads to ask additional questions about the same problem, just add another post to the thread you already created. Its less confusing for everyone.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.