![subject](/tpl/images/cats/informatica.png)
Computers and Technology, 16.03.2020 17:38 KingJayDevil
Write a function sample_median(n, P) that generates n random values using distribution P and returns the median of the collected sample. Hint: Use function random. choice() to sample data from P and median() to find the median of the samples * Sample run * print(sample_median(10,[0.1 0.2 0.1 0.3 0.1 0.2])) print(sample_median(10,[0.1 0.2 0.1 0.3 0.1 0.2])) print(sample_median(5,P=[0.3,0.7]) print(sample_median(5,P=[0.3,0.7]) * Expected Output * 4.5 4.0 2.0 1.0
![ansver](/tpl/images/cats/User.png)
Answers: 1
Another question on Computers and Technology
![question](/tpl/images/cats/informatica.png)
Computers and Technology, 23.06.2019 15:00
In the blank libreoffice writer document, to start the process of entering a date field into a letter, click on the insert menu. edit menu. file menu. fields menu.
Answers: 3
![question](/tpl/images/cats/informatica.png)
Computers and Technology, 24.06.2019 11:00
Each row in a database is a set of unique information called a(n) ? a.) table. b.) record. c.) object. d.) field.
Answers: 2
![question](/tpl/images/cats/informatica.png)
Computers and Technology, 24.06.2019 11:30
Convert 11001110(acdd notation) into decimal
Answers: 2
![question](/tpl/images/cats/informatica.png)
Computers and Technology, 24.06.2019 14:30
Which computer network component connects two different networks together and allows them to communicate? a is a node (or a device) that connects two different networks together and allows them to communicate.
Answers: 1
You know the right answer?
Write a function sample_median(n, P) that generates n random values using distribution P and returns...
Questions
![question](/tpl/images/cats/fizika.png)
![question](/tpl/images/cats/mat.png)
![question](/tpl/images/cats/mat.png)
![question](/tpl/images/cats/mat.png)
Mathematics, 20.11.2020 19:10
![question](/tpl/images/cats/biologiya.png)
Biology, 20.11.2020 19:10
![question](/tpl/images/cats/en.png)
![question](/tpl/images/cats/mat.png)
Mathematics, 20.11.2020 19:10
![question](/tpl/images/cats/mat.png)
![question](/tpl/images/cats/mat.png)
![question](/tpl/images/cats/biologiya.png)
![question](/tpl/images/cats/obshestvoznanie.png)
Social Studies, 20.11.2020 19:10
![question](/tpl/images/cats/mat.png)
![question](/tpl/images/cats/mat.png)
![question](/tpl/images/cats/en.png)
![question](/tpl/images/cats/mat.png)
![question](/tpl/images/cats/himiya.png)
Chemistry, 20.11.2020 19:10
![question](/tpl/images/cats/en.png)
![question](/tpl/images/cats/mat.png)
![question](/tpl/images/cats/mat.png)
Mathematics, 20.11.2020 19:10