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
ira [324]
4 years ago
14

Write a program that simulates flipping a coin to make decisions. The input is how many decisions are needed, and the output is

either heads or tails. Assume the input is a value greater than 0.
Computers and Technology
1 answer:
Nataly [62]4 years ago
7 0

Answer:

import random

decisions = int(input("How many decisions: "))

for i in range(decisions):

   number = random.randint(0, 1)

   if number == 0:

       print("heads")

   else:

       print("tails")

Explanation:

*The code is in Python.

import the random to be able to generate random numbers

Ask the user to enter the number of decisions

Create a for loop that iterates number of decisions times. For each round; generate a number between 0 and 1 using the randint() method. Check the number. If it is equal to 0, print "heads". Otherwise, print "tails"

You might be interested in
The Word feature that would allow you to insert fields from an Access database into multiple copies of a Word document is called
Arte-miy333 [17]

Answer:

Mail Merge.

Explanation:

Microsoft Word refers to a word processing software application or program developed by Microsoft Inc. to enable its users type, format and save text-based documents.

Microsoft Access can be defined as a software application or program designed by Microsoft corporation to avail end users the ability to create, manage and control their database.

A Mail Merge is a Microsoft Word feature that avails end users the ability to import data from other Microsoft applications such as Microsoft Access and Excel. Thus, an end user can use Mail Merge to create multiple documents (personalized letters and e-mails) at once and send to all individuals in a database query or table.

Hence, the Word feature that would allow you to insert fields from an Access database into multiple copies of a Word document is called Mail Merge.

3 0
3 years ago
Describe four features of a well designed input screen
Sladkaya [172]

Answer:

A well design input screen should:1.Be titled2.Navigation aids should be used

Explanation:

3 0
3 years ago
Read 2 more answers
Match the data type to their correct explanations,
sergejj [24]

Answer:

I'm positive memo is "allows inserting a large amount of text including numbers" i just took the test on Plato and got everything wrong but that one

4 0
3 years ago
Read 2 more answers
How do you activate the Slicer Tools contextual tab?
Strike441 [17]

Answer:

i need this one too

Explanation:

4 0
3 years ago
Press the enter key in all of the following circumstances except _____.
fiasKO [112]
B. When the insertion point reaches the right margin 
6 0
3 years ago
Other questions:
  • What does SMTP stand for?
    6·2 answers
  • Professional photography is a competitive job field. <br> true <br> false
    12·2 answers
  • How can you print a mailing label in word
    13·1 answer
  • LAB:
    8·1 answer
  • Cliff just started working with a client who has a very disorganized AdWords account. What’s an effective way for him to begin r
    15·1 answer
  • What is the output of executing the code segment?
    7·1 answer
  • AI in processing capability of computer yes or no​
    13·2 answers
  • Who you think is better? Ninja or TFue ,btw do you know who icebear is?
    9·1 answer
  • state how to transfee information from website to el processing document in computers and technology.​
    12·1 answer
  • State two skills to be used to access information from the internet in order to avoid unwanted materials.
    9·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!