Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

This is my code please help int sumarray (int *array[]); int main(int argc, char

ID: 3641444 • Letter: T

Question

This is my code please help

int sumarray (int *array[]);

int main(int argc, char *argv[])
{
    int x;
    x = GetInteger();
   int array [x];
    int sol;

        for( int i=0; i < x; ++i){
            for( int j=5; i < 100; ++j)
                *array [i] = j;
        printf("(%d)-> [%d]", i, array [i]);
    sol = sumarray (&array[i]);
    printf("(%d)", sol);
    }
   

    return 0;
}

int sumarray (int *array[])
{
    int sum =0 ;
    int x;
    x = GetInteger();
        for( int i=0; i < x; ++i)
            sum = sum + *array[i];

    return sum;
}

Explanation / Answer

#include int sumarray (int array[],int size); int main(int argc, char *argv[]) { const int x=5; //x = GetInteger(); int array [x]; int sol; for( int i=0; i
Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote