Intro to Python-Homework 3-INT-2240

Intro to Python-Homework 3-INT-2240

Intro to Python-Homework 3-

  1. Training Heart Rate The American College of Sports Medicine recommends that you maintain your training heart rate during an aerobic workout. Your training heartrate is computed as.7 * (220 – a) + .3 * r,where “a” is your age and “r” is your restingheart rate (your pulse when you first awaken). Write a program to request a person’sage and resting heart rate and display their training heart rate.ExampleEnter your age: 20Enter your resting heart rate: 70Training heart rate: 161 beats/min.
  2. Price of Ketchup The following steps compute the price of ketchup.This should be done inside a function(a) Create the variable “item” and assign it the value “ketchup”.(b) Create the variable “regularPrice” and assign it the value 1.80.(c) Create the variable “discount” and assign it the value .27.(d) Display the phrase “1.53 is the sale price of ketchup.” using the print() function.
  3. What is the output of the program:def main():     massKg = 50     # since one stone is equal to 14 pounds     massStone(massKg * 2.2 / 14 )def massStone(num):    print(“You weigh”, num, “stone.”)main()

Answer Preview-Intro to Python-Homework 3-INT-2240

Intro to Python-Homework 3-INT-2240

$3.00

Posted

in

by

Tags: