def one(iterable):
	"""Return the single element in iterable.

	Raise an error if there isn't exactly one element.
	"""
	item = None
	iterator = iter(iterable)
	try:
		item = next(iterator)
	except StopIteration:
		raise ValueError('Iterable is empty, must contain one item')
	try:
		next(iterator)
	except StopIteration:
		return item
	else:
		raise ValueError('object contains >1 items, must contain exactly one.')