June 2024
Beginner to intermediate
908 pages
15h 59m
English
Write a Python program that lets the user enter 100 positive numerical values into a list. Then, the program must create a new list of 98 elements. This new list must contain, in each position the average value of the three elements that exist in the current and the next two positions of the user-provided list.
Solution
Let's try to understand this exercise through an example using 10 elements.

List newArr is the new list that is created. In list newArr, the element at position 0 is ...
Read now
Unlock full access