Answer to Question #348900 in Python for kavya

Question #348900

mean median mode assignment question

input:1

Mean: 4.67

Median: 4.5

Mode: 2

input:2

Mean: 5.45

Median: 3

Mode: 2 3

not getting desired output for input1 in median case, please debug the code


1
Expert's answer
2022-06-08T17:24:01-0400
import statistics

sample = [2, 2, 3.36, 4, 5, 6, 7, 8]

mean = statistics.mean(sample)
median = statistics.median(sample)
mode = statistics.mode(sample)

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Comments

No comments. Be the first!

Leave a comment

LATEST TUTORIALS
New on Blog
APPROVED BY CLIENTS