Question: List trend _ data contains integers read from input, representing a sequence of data values. For each index i of trend _ data from 1

List trend_data contains integers read from input, representing a sequence of data values. For each index i of trend_data from 1 through the second-to-last index:
The element at index i is a dunk if the element is less than both the preceding element and the following element.
If the element at index i is a dunk, then output 'Dunk: ', followed by the preceding element, the current element, and the following element, separating each element by a space.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!