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
kaheart [24]
3 years ago
9

Implement the simulation of a biased 6-sided die which takes the values 1,2,3,4,5,6 with probabilities 1/8,1/12,1/8,1/12,1/12,1/

2. In [ ]: # WRITE YOUR OWN CODE HERE! FEEL FREE TO INSERT MORE CELLS! # ADD SOME COMMENTS TO YOUR CODE! ​ Plot a histrogramm with 1,000,000 simulations to check if the relative counts of each number is approximately equal to the corresponding specified probabilities. Remark: Specify the bins of your histogram correctly.

Computers and Technology
1 answer:
hjlf3 years ago
4 0

Answer:

see explaination

Explanation:

import numpy as np

import matplotlib.pyplot as plt

a = [1, 2, 3, 4, 5, 6]

prob = [1.0/8.0, 1.0/12.0, 1.0/8.0, 1.0/12.0, 1.0/12.0, 1.0/2.0]

smls = 1000000

rolls = list(np.random.choice(a, smls, p=prob))

counts = [rolls.count(i) for i in a]

prob_exper = [float(counts[i])/1000000.0 for i in range(6)]

print("\nProbabilities from experiment : \n\n", prob_exper, end = "\n\n")

plt.hist(rolls)

plt.title("Histogram with counts")

plt.show()

check attachment output and histogram

You might be interested in
Integrity constraints are enforced by Group of answer choices A. The operating system B. The end user C. The database designer D
slega [8]

Integrity constraints are enforced by The database designer.

<h3>What are Integrity constraints?</h3>

An  Integrity Constraints is known to be the protocols that a table's data columns is mandated to follow.

Note that they are used to hinder the types of information that can be put into a table and as such, Integrity constraints are enforced by The database designer.

Learn more about Integrity constraints from

brainly.com/question/28026113

#SPJ1

4 0
2 years ago
Which one did I buy the iPhone 13 or the Samsung S22 Ultra?
SVETLANKA909090 [29]

Answer:

iphone 13

Explanation:

6 0
2 years ago
Read 2 more answers
You want to drive traffic to a new landing page for a campaign, and want a web address that's short, easy to remember, trackable
Akimi4 [234]

Hootsuite supports you with vanity URLs.

1. vanity URLs

<u>Explanation:</u>

Since the website webpage is landing on campaign, heavy network traffic is expected. Better to have multiple URL methods but it will not solve the purpose of heavy of network access of webpage or web site. Better to use vanity URLS methods to use heavy network traffic.

Vanity URLS means is customizable redirecting or rerouting by branding links or customized URL link. These type of vanity URLS by choosing hosting service and customize link been created. So end user can use link.

6 0
3 years ago
Which of the following will most likely result in a decrease in population?
balu736 [363]
The correct answer is B
4 0
3 years ago
Read 2 more answers
How do I type over Images (photo posted ​
Ber [7]
Oh a document, I do not believe that you have type on images, but if you were to type a text in a app called PicsArt and saved it and then put it onto the document over the picture it would work.
3 0
2 years ago
Read 2 more answers
Other questions:
  • Your manager asks you to calculate the sale price if the product is marked down 20 percent. You enter the original price in cell
    9·1 answer
  • In order to make burger a chef needs the following ingredients one piece of chicken meat 3 lettuce leaves 6 tomato slices Write
    8·1 answer
  • What two programming systems uses numbers and text?
    6·1 answer
  • Effective display designs must provide all the necessary data in the proper sequence to carry out the task. Identify a recent pe
    12·1 answer
  • Lifelong learning _____. is only important for professionals with advanced degrees can be formal or informal includes formal cla
    12·1 answer
  • Which page in a web site do viewers usually see first?
    15·1 answer
  • Selma writes the following four answers in her Computer Science examination.
    8·2 answers
  • Please answer this simple (hard) question for me lol
    13·2 answers
  • Alfred works in the human resources department, and he uses a management information system to find applicants' résumés on the w
    7·1 answer
  • What is one of four key principles of Responsible Artificial Intelligence
    5·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!