subject

Prompt: A half-life is the amount of time it takes for a substance or entity to fall to half its original value. Caffeine has a half-life of about 6 hours in humans. Given caffeine amount (in mg) as input, output the caffeine level after 6, 12, and 24 hours. Use a string formatting expression with conversion specifiers to output the caffeine amount as floating-point numbers. Output each floating-point value with two digits after the decimal point, which can be achieved as follows:
print('{:.2f}'.format(your_value))< br />
Ex: If the input is:

100
the output is:

After 6 hours: 50.00 mg
After 12 hours: 25.00 mg
After 24 hours: 6.25 mg

my code:
caffeine_mg = float(input())

six_hours = caffeine_mg / 2
twelve_hours = six_hours / 2
twenty_four_hours = twelve_hours / 4

print('After 6 hours: {:.2f}'.format(six_hours))
print('After 12 hours: {:.2f}'.format(twelve_hours))
print('After 24 hours: {:.2f}'.format(twenty_four_hours))< br />
Question: How do I add "mg" at the end? This is my output
After 6 hours: 50.00
After 12 hours: 25.00
After 24 hours: 6.25

ansver
Answers: 2

Another question on Computers and Technology

question
Computers and Technology, 21.06.2019 17:00
Which process would best represent the opposite of exhausting air from a system?
Answers: 2
question
Computers and Technology, 22.06.2019 14:30
Create a pseudocode design to prompt a student for their student id and the titles of the three classes they want to add. the solution should display the student’s id and a total bill. • bill a student using the following rules: o students can only add up to 3 classes at a time.
Answers: 3
question
Computers and Technology, 23.06.2019 14:00
Technician a says that with self-adjusting clutch systems, the release bearing constantly rotates. technician b says that the ball bearing portion of the release bearing should be lubricated with high-temperature grease during routine maintenance. which technician is correct?
Answers: 2
question
Computers and Technology, 23.06.2019 20:50
3.11.3 quiz: comparing and analyzing function typesquestion 4 of 102 pointswhat can you say about the y-values of the two functions f(x) = 3x2-3 andg(x)=2* - 3?
Answers: 2
You know the right answer?
Prompt: A half-life is the amount of time it takes for a substance or entity to fall to half its ori...
Questions
question
Mathematics, 21.12.2020 05:30
question
English, 21.12.2020 05:30
question
Physics, 21.12.2020 05:30
question
Geography, 21.12.2020 05:30
question
Mathematics, 21.12.2020 05:30
Questions on the website: 13722367