Question: Exercise 2 (2 points). Write a function, get index(CS, alpha), that takes a list CS and threshold alpha as inputs and returns the position, index,

Exercise 2 (2 points). Write a function, get index(CS, alpha), that takes a list CS and threshold alpha as inputs and returns the position, index, of the first element such that CSlindex] > alpha. For example alpha = 12 assert get_index (CS, alpha)11 If no such element is found in cS, the function should return In def get_index(cs, alpha): YOUR CODE HERE
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
