Question: Create one python file that answers the following three questions: 1. Write a loop that replaces each number in a list named data with its
Create one python file that answers the following three questions: 1. Write a loop that replaces each number in a list named data with its absolute value. You can use function abs(number) to return the absolute value of a number. . data [4,-23,5,8,-1,-47, 25] = #your code starts from here 2. Define a function named sum. This function expects two numbers, named low and high, as arguments. The function computes and returns the sum of all of the numbers between low and high, inclusive. 3. Assume that the variable telephone refers to the dictionary tomar":6882231, amjad" : 9761276, "nadia":6819922). Write the code that removes amjad from the dictionary, then adds your name as a key and your telephone number then prints the keys and their values in alphabetical order based on key telephone = {'omar': 66891221, amjad' :99775431, 'nadia' 6662311) # your code starts from here
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
