practice_C

Array Operations

Exercises

  1. Find the largest element in an array.
  2. Calculate the sum of the second and second-last elements of an array.
  3. Copy the elements of one array into another array.
  4. Count the odd and even elements of an array.

Note

The second exercise intentionally means positions 2 and n - 1, using one-based position wording.

Click here for explanation and solution.