list L Solved C language

15.00 $

Click Category Button to View Your Next Assignment | Homework

You'll get a download link with a: . zip solution files instantly, after Payment


5/5 - (2 votes)
Suppose we have the following input list L:
a) Complete the function spliceinto (L, x, i) which inserts the integer x into index location i of list L. If location i >= length of list L, then it appends node containing x at the end. For example:
c) Complete the function removeNumber (L, target) which removes (all instances of the target from Lif target is found in L and does nothing otherwise. If successfully removed, return 0. Otherwise, return 1. // Post: removes data target from list L unsigned int removeNumber (LL_t * L, int target) {
d) Complete the function numberOfEvens (L) which counts the number of even numbers in L and returns that number. In our list, the answer would be 5. // Post: returns the number of even numbers from list L unsigned int numberOfEvens (LL_t * L) {