1
2
3
4
5
6
|
import statistics
class Solution:
def average(self, salary: List[int]) -> float:
salary.sort()
salary=salary[1:-1]
return statistics.mean(salary)
|
cs |
반응형
'python-algorithm' 카테고리의 다른 글
leetcode 389. Find the Difference (0) | 2022.03.24 |
---|---|
leetcode 1394. Find Lucky Integer in an Array (0) | 2022.03.24 |
leetcode 1991. Find the Middle Index in Array (0) | 2022.03.24 |
leetcode 1619. Mean of Array After Removing Some Elements (0) | 2022.03.23 |
leetcode 349. Intersection of Two Arrays (0) | 2022.03.23 |
댓글