https://github.com/candytale55/middle_element---python
Function middle_element takes one parameter lst(a list). If there are an odd number of elements in lst, the function should return the middle element. If there are an even number of elements, the function should return the average of the middle two elements.
https://github.com/candytale55/middle_element---python
Last synced: about 1 year ago
JSON representation
Function middle_element takes one parameter lst(a list). If there are an odd number of elements in lst, the function should return the middle element. If there are an even number of elements, the function should return the average of the middle two elements.
- Host: GitHub
- URL: https://github.com/candytale55/middle_element---python
- Owner: candytale55
- Created: 2020-12-15T12:32:09.000Z (over 5 years ago)
- Default Branch: main
- Last Pushed: 2020-12-15T12:37:49.000Z (over 5 years ago)
- Last Synced: 2023-05-29T01:21:01.738Z (about 3 years ago)
- Language: Python
- Size: 1000 Bytes
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0