← 返回 cisco 的题目列表Find the Mean and Mode of Numbers
类型:online_judge
Given a list of integers, find the mean and mode of the numbers. The input consists of an integer N, representing the length of the list followed by N integers. The output should be the mean and mode, with the mean rounded to one decimal place. If there are multiple modes, return the smallest one.
Input: N: An integer representing the length of the array Numbers: N space-separated integers
Output: Mean and mode separated by a space.
Sample Input: 5 1 2 3 2 3
Sample Output: 2.2 2
Example
Input
5
1 2 3 2 3