Programming Examples
Python program to obtain the marks in computer of some student and find mean median and mode
The Computer marks obtained by some students are given below:
89,91,96,94,96,88,91,92,95,99,91,97,91
Write a python code to calculate and display mean, median and mode.
import statistics
mn=statistics.mean([89,91,96,94,96,88,91,92,95,99,91,97,91])
mid=statistics.median([89,91,96,94,96,88,91,92,95,99,91,97,91])
md=statistics.mode([89,91,96,94,96,88,91,92,95,99,91,97,91])
print("Mean ",mn)
print("Median ",mid)
print("Mode ",md)
Output/ Explanation: