Given an array of numbers, return the difference between the largest and smallest values. 

For example:

`[23, 3, 19, 21, 16]` should return `20` (i.e., `23 - 3`).

`[1, 434, 555, 34, 112]` should return `554` (i.e., `555 - 1`).

The array will contain a minimum of two elements. Input data range guarantees that `max-min` will cause no integer overflow.

Source: codewars | Difficulty: EASY
Tags: Fundamentals

Data structures

Starter code: def between_extremes(numbers):
	

Solutions:
def between_extremes(numbers):
	return max(numbers) - min(numbers)


def between_extremes(ns):
	return max(ns) - min(ns)


def between_extremes(a):
	return max(a) - min(a)


def between_extremes(numbers):
	return max(numbers) - min(numbers)

def between_extremes(numbers):
	(mini, maxi) = (float('inf'), -float('inf'))
	for x in numbers:
		if x > maxi:
			maxi = x
		if x < mini:
			mini = x
	return maxi - mini


between_extremes = lambda n: max(n) - min(n)


def between_extremes(numbers):
	(a, *b, c) = sorted(numbers)
	return c - a


def between_extremes(numbers):
	minimum_value = min(numbers)
	maximum_value = max(numbers)
	output = maximum_value - minimum_value
	return output


def between_extremes(lst):
	lst = set(lst)
	return max(lst) - min(lst)


def between_extremes(numbers):
	numbers.sort()
	b = numbers[-1] - numbers[0]
	return b