Answered step by step
Verified Expert Solution
Question
1 Approved Answer
# 3. Write a function to make a new list made up of every nth element in the # original list. When saving sound on
# 3. Write a function to make a new list made up of every nth element in the # original list. When saving sound on a computer we can choose how many samples # to save. More samples means higher quality. The function will shrink the number # of samples but also reduce the quality. # If the original list is [1,2,3,4,5,6,7,8] and skip is 3, the new list should be # [1,4,7]. # You may not use original_list[::skip], you must use a loop to find the desired # elements and build up a new list. As a hint, this is a problem best solved # using a loop over the index numbers of the list rather than the elements of the # list. Return the new list. def make_reduced_samples(original_samples, skip): # Add code to make the function work as specified. return [] # Replace this line with your own code
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started