Write a function `sumTimesTables` which sums the result of the sums of the elements specified in `tables` multiplied by all the numbers in between `min` and `max` including themselves.

For example, for `sumTimesTables([2,5],1,3)` the result should be the same as
```
2*1 + 2*2 + 2*3 +
5*1 + 5*2 + 5*3
```
i.e. the table of two from 1 to 3 plus the table of five from 1 to 3

All the numbers are integers but you must take in account:

* `tables` could be empty.
* `min` could be negative.
* `max` could be really big.

Difficulty: EASY
Starter code: def sum_times_tables(table,a,b):
	

Solutions:
def sum_times_tables(table, a, b):
	return sum(table) * (a + b) * (b - a + 1) // 2


def sum_times_tables(table, a, b):
	s = 0
	for i in range(a, b + 1):
		s = s + i * sum(table)
	return s


def sum_times_tables(table, a, b):
	return sum(table) * sum(range(a, b + 1))


def T(n):
	return n * (n + 1) // 2

def sum_times_tables(table, a, b):
	return sum(table) * (T(b) - T(a - 1))


def sum_times_tables(table, a, b):
	n = sum(table)
	return n and sum(range(n * a, n * (b + 1), n))


def sum_times_tables(table, a, b):
	total = 0
	for x in range(a, b + 1):
		total += sum(list([x * n for n in table]))
	return total


def sum_times_tables(table, a, b):
	return sum(table) * (summa(b) - summa(a - 1))

def summa(n):
	return n * (n + 1) / 2


def sum_times_tables(table, a, b):
	return sum((x * y for x in table for y in range(a, b + 1)))


def sum_times_tables(table, a, b):
	return sum(list(map(lambda x: sum(list(map(lambda y: y * x, range(a, b + 1)))), table)))