Question: Hi I need help writing the code for these three Problems . This is python 3 FYI Everything needed to solve is shown in the
def hasMultiplesof (x, listofNums): - Returns True if ALL items in listOfNums are multiples of x. - theList can have elements of any type - If listofNums is not a list type, return - If listOfNums is empty, return False since no of x False. items are a multiple -If listofNums contains an element that is not float), return False. return "stub" a number (int or def countEvens (listofInts): - Returns an integer value representing the number of even numbers that exist in listOfInts. - Return 0 if listofInts is not a list type or if no even number exists in listofInts. - Note: elements in 1istofInts can contain any data type return "stub" def computeGrade (percentage): - Return the corresponding letter grade string based on the value of percentage using the following scale: [100 90 A (90 80]: B' (80-70] : '. (70 60: D (60 0 :'F" - If percentage is not a number type (int or float) OR if percentage is outside the range of [100 0, return an empty string ( return "stub
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
