Basic Instructions 4
Classwork:
This assignments can be done with the most basic set of instructions:
####################################### # # G Elia # Program to calcualte the range of a # set of numbers # 9/21 # python 3.4 # ######################################## yesNo ="y" smallest =int(input("Enter number: ")) while yesNo == "y": y=int(input("Enter another: ")) if smallest > y: smallest = y yesNo = input("Would you like to continue? (y/n) ") print("The smallest number is",smallest)
Make the change to the brain according to the different assignments.
If you are finished with the previous assignments, work on YI_BasicInstructions4.py to calculate the range of a set.
Homework: Write a program YI_StandarDeviation.py to calculate the standard deviation of a set of numbers.
The standard deviation for a set of 5 numbers is calculated with this formula:
where N is the total number of values entered,in this case 5, is each value and is the mean of all the values.
Look into the Documentation page to find out how to find the square root.
NOTE: import math at the top of your program