1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Flauer [41]
3 years ago
12

In Coral programming: A half-life is the amount of time it takes for a substance or entity to fall to half its original value. C

affeine 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 18 hours.
Ex: If the input is 100, the output is:

After 6 hours: 50.0 mg
After 12 hours: 25.0 mg
After 18 hours: 12.5 mg
Note: A cup of coffee has about 100 mg. A soda has about 40 mg. An "energy" drink (a misnomer) has between 100 mg and 200 mg.
Computers and Technology
1 answer:
viva [34]3 years ago
7 0

Answer:

Yes, it will be after 6 hours: 50 mg, after 12 hours: 25 mg, and after 18 hours: 12.5 mg

Explanation:

Remember coral is a functional programming language and follows Pythons functional programming paradigm. Remember Python supports functional, imperative as well as OOPS paradigm.

The function will be:

def void calcamtleft(int amt):

   integer a=6

   integer time=6

   integer i=1

   while amt> 0:

       amt=amt/2

       print("After"+time+"  hours:" +amt+"mg")

       i++

       time=a* i

Hence in first loop amt=100

new amt=100/2=50

After 6 hours: 50 mg ( this will be printed)

i will increment then, and time will be = 6 *2 =12

now input amt=50

new amt=50/2=25

After 12 hours 25 mg (this will be output)

i will increment then, and time will be = 6 *3 =18

now input amt=25

new amt=25/2=12.5

After 18 hours 12.5 mg (this will be output)

i will increment then, and time will be = 6 *4 =24

now input amt=12.5/2= 6.25

new amt=6.25/2= 3.125

After 24 hours 3.125 mg (this will be output)

i will increment then, and time will be = 6 *5 =30

now input amt=3.125

new amt=3.125/2= 1.5625

After 30 hours 1.5625 mg

And this will continue till amt>0

You might be interested in
Where you should go to find out what access the system and users to a file ​
dsp73

Answer:

To see who reads the file, open “Windows Event Viewer”, and navigate to “Windows Logs” → “Security”. There is a “Filter Current Log” option in the right pane to find the relevant events. If anyone opens the file, event ID 4656 and 4663 will be logged.

4 0
3 years ago
Memory is a _____________ that includes the organization and shaping of information by processing, storage, and retrieval of inf
vaieri [72.5K]

Answer:

A. <em>Encoding Process </em>

Explanation:

Memory is an <em>encoding process </em>that includes the organization and shaping of information by processing, storage, and retrieval of information.

There are two types of memory in computing, <em>RAM </em>and <em>ROM</em>. <em>RAM </em>stands for <em>Random Access Memory</em>. It I the core memory of the computer and it is especially faster regarding reading and writing process. As an analogy, RAM memory is like the “<em>Short-term</em>” memory of the computer. <em>ROM </em>stands for <em>Read-Only Memory</em>, this is the type of memory in charge of permanently storing data in the computer. It contains the necessary information to run the computer. As an analogy, <em>ROM </em>memory is like the “<em>long-term</em>” memory of the computer.

3 0
3 years ago
Which of the following includes premium content you must pay to use?<br> On word
kotykmax [81]

Some premium contents on Microsoft Word that you must pay before using them include:

  • 1 TB of OneDrive cloud storage
  • Advanced security
  • Expanded technical support
  • Premium templates, among others.

<h3>What are Premium Contents or Features?</h3>

Premium contents or features are exclusive features that have higher quality when compared to the usual quality. In an application like Microsoft Word, there are premium contents or features that can only be used or made available when you subscribe.

Some premium contents on Microsoft Word that you must pay before using them include:

  • 1 TB of OneDrive cloud storage
  • Advanced security
  • Expanded technical support
  • Premium templates, among others.

Learn more about premium contents on:

brainly.com/question/24749457

5 0
2 years ago
Why were video games invented?
Alenkinab [10]
The answer is in the following website: https://www.reference.com/history/were-video-games-invented-e9413d3dc1378766


4 0
3 years ago
1. Felipe looks over his presentation, and he notices that some of his words are written in bold and some are written in italic.
romanna [79]
 <span>Felipe looks over his presentation, and he notices that some of his words are written in bold and some are written in italic.</span>His ability to remember these differences is an example of Retroactive encoding. Even though you didn't share the options, I am pretty sure this one will help!

4 0
3 years ago
Other questions:
  • Read each statement below. If the statement describes a peer-to-peer network, put a P next to it. If the statement describes a s
    13·2 answers
  • Which of the following do you need to remeber about true/false questions?
    12·1 answer
  • What is the financial aspect for a business as to what database software they will buy?
    6·1 answer
  • Plot element is typically the turning point in the most intense moment of a story
    8·1 answer
  • If you wanted to have wireless connectivity in your home or​ apartment, you would need a​ _________________ to move packets of d
    11·1 answer
  • Danielle, a help desk technician, receives a call from a client. In a panic, he explains that he was using the Internet to resea
    8·1 answer
  • What is the importance of the international employment​
    8·2 answers
  • Which kind of typography focuses on the details of a character?
    10·1 answer
  • (Print distinct numbers) Write a program that reads in integers separated by a space in one line and displays distinct numbers i
    8·1 answer
  • An instruction for the computer. Many commands put together to
    5·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!