# Messi goals function

[Messi](https://en.wikipedia.org/wiki/Lionel_Messi) is a soccer player with goals in three leagues: 

- LaLiga
- Copa del Rey
- Champions

Complete the function to return his total number of goals in all three leagues.

Note: the input will always be valid.

For example:

```
5, 10, 2  -->  17
```

Difficulty: EASY
Tags: Fundamentals

Starter code:
def goals(laLiga, copaDelRey, championsLeague):
	

Solutions:
def goals(*a):
	return sum(a)


def goals(*args):
	return sum(args)


def goals(laLiga, copaDelRey, championsLeague):
	return laLiga + copaDelRey + championsLeague


def goals(laLiga, copaDelRey, championsLeague):
	resultado = laLiga + copaDelRey + championsLeague
	return resultado
goals(5, 10, 5)


goals = lambda *a: sum(a)


def goals(laliga, copa_del_rey, champions):
	return laliga + copa_del_rey + champions
print(f"Final result of Messi's goals is {goals(5, 10, 2)}.")


def goals(*leagues):
	return sum(leagues)


goals = lambda *b: sum(b)


MESSI_IS_THE_BEST_FOOTBALLER_EVER = True

def goals(laLiga, copaDelRey, championsLeague):
	if MESSI_IS_THE_BEST_FOOTBALLER_EVER:
		return laLiga + copaDelRey + championsLeague


goals = lambda *leagues: sum(leagues)


goals = lambda *params: sum(params)


import itertools

def goals(laLiga, copaDelRey, championsLeague):
	return list(itertools.accumulate([laLiga, copaDelRey, championsLeague]))[-1]


def goals(laLiga, copaDelRey, championsLeague):
	sum = int(laLiga) + int(copaDelRey) + int(championsLeague)
	return sum


def goals(l, c, m):
	return l + c + m


def goals(LaLiga, CopaDelRey, ChampionsLeague):
	return LaLiga + CopaDelRey + ChampionsLeague


def goals(laLiga, copaDelRey, championsLeague):
	l = laLiga
	c = copaDelRey
	ch = championsLeague
	return l + c + ch
	pass


def goals(*argv):
	return sum(argv)


goals = lambda l, co, ch: l + co + ch


def goals(*games):
	return sum(games)


def goals(first, second, third):
	return first + second + third


import numpy as np

def goals(laLiga, copaDelRey, championsLeague):
	a = np.array((laLiga, copaDelRey, championsLeague))
	return sum(a)


def goals(laLiga, copaDelRey, championsLeague):
	count_goals = laLiga + copaDelRey + championsLeague
	return count_goals if count_goals > 0 else 0


goals = lambda a, b, c: sum((a, b, c))


def goals(*args):
	return sum([x for x in args])


def goals(l, c1, c2):
	return l + c1 + c2


def goals(a, b, c):
	return a + c + b


def goals(*goals):
	return sum(goals)


def goals(l, cy, ch):
	return l + cy + ch


def goals(laLiga, copaDelRey, championsLeague):
	count = 0
	for i in range(laLiga):
		count += 1
	for j in range(copaDelRey):
		count += 1
	for k in range(championsLeague):
		count += 1
	return count


def goals(*c):
	return sum(c)


def goals(x, y, z):
	return sum([x, y, z])


def goals(a, e, o):
	return a + e + o


def goals(l, cdl, cl):
	return l + cdl + cl


def goals(a, b, e):
	return a + b + e


def goals(laLiga, copaDelRey, championsLeague):
	pass
	goals = laLiga + copaDelRey + championsLeague
	return goals
goals(1, 1, 1)


def goals(*goles):
	return sum([*goles])


def goals(laLiga, copaDelRey, championsLeague):
	if laLiga >= 0 and copaDelRey >= 0 and (championsLeague >= 0):
		return laLiga + copaDelRey + championsLeague
	else:
		print('the input will always be valid')


goals = lambda *s: sum(s)


def goals(l, d, s):
	return l + d + s


def goals(laLiga, copaDelRey, championsLeague):
	_sum = (laLiga, copaDelRey, championsLeague)
	return sum(_sum)


def goals(*agr):
	return sum(agr)


def goals(laLiga, copaDelRey, championsLeague):
	total_goals = (laLiga, copaDelRey, championsLeague)
	return sum(total_goals)


def goals(laLiga, copaDelRey, championsLeague):
	sum = laLiga + copaDelRey + championsLeague
	return sum
goals(5, 10, 15)


def goals(laLiga=0, copaDelRey=0, championsLeague=0):
	total_goals = laLiga + copaDelRey + championsLeague
	return total_goals


def goals(laLiga, copaDelRey, championsLeague):
	return sum(locals().values())


def goals(la, c, ch):
	return sum([la, c, ch])


goals = lambda laLiga, copaDelRey, championsLeague: sum([laLiga, copaDelRey, championsLeague])


from functools import reduce

def goals(laLiga, copaDelRey, championsLeague):
	return reduce(lambda x, y: x + y, [laLiga, copaDelRey, championsLeague])


def goals(l, c, ca):
	return l + c + ca


def goals(laLiga, copaDelRey, championsLeague):
	if laLiga >= 0 and copaDelRey >= 0 and (championsLeague >= 0):
		return laLiga + copaDelRey + championsLeague


def goals(laLiga, copaDelRey, championsLeague):
	total_goals = int(laLiga) + int(copaDelRey) + int(championsLeague)
	return total_goals
	pass


def goals(l, c, e):
	return l + c + e


def goals(*s):
	return sum(s)


def goals(laLiga, copaDelRey, championsLeague):
	return laLiga + copaDelRey + championsLeague
x = goals(5, 10, 2)
print(x)


def goals(laLiga, copaDelRey, championsLeague):
	goal = lambda a, b, c: a + b + c
	return goal(laLiga, copaDelRey, championsLeague)


def goals(laLiga, copaDelRey, championsLeague):
	res = laLiga + copaDelRey + championsLeague
	return res
print(goals(5, 12, 7))


def goals(laLiga, copaDelRey, championsLeague):
	a = laLiga
	b = copaDelRey
	c = championsLeague
	x = a + b + c
	return x


def goals(laLiga, copaDelRey, championsLeague):
	list = [laLiga, copaDelRey, championsLeague]
	return sum(list)


def goals(*args):
	leagues = [*args]
	return sum(leagues)


def goals(laLiga, copaDelRey, championsLeague):
	all = [laLiga, copaDelRey, championsLeague]
	return sum(all)


def goals(laLiga, copaDelRey, championsLeague):
	somme = sum([laLiga, copaDelRey, championsLeague])
	print(somme)
	return somme


goals = lambda ll, cd, cl: ll + cd + cl


def goals(laLiga, copaDelRey, championsLeague):
	x = sum((laLiga, copaDelRey), championsLeague)
	return x


def goals(laLiga, copaDelRey, championsLeague):
	total = [laLiga, copaDelRey, championsLeague]
	return sum(total)


def goals(laLiga, copaDelRey, championsLeague):
	a = sum((laLiga, copaDelRey, championsLeague))
	return a


def goals(laLiga, copaDelRey, championsLeague):
	return laLiga + copaDelRey + championsLeague
print(goals(5, 6, 9))


def goals(laLiga, copaDelRey, championsLeague):
	return laLiga + copaDelRey + championsLeague
goals(4, 5, 12)


def goals(laLiga, copaDelRey, championsLeague):
	alltogetherforever = 0
	for point in (laLiga, copaDelRey, championsLeague):
		alltogetherforever += point
	return alltogetherforever


def goals(laLiga, copaDelRey, championsLeague):
	messi = laLiga + copaDelRey + championsLeague
	print(messi)
	return messi


def goals(laLiga, copaDelRey, ChampionsLeague):
	total_goals = laLiga + copaDelRey + ChampionsLeague
	return total_goals


def goals(laLiga, copaDelRey, championsLeague):
	counter = 0
	for n in [laLiga, copaDelRey, championsLeague]:
		counter += n
	return counter


def goals(laLiga, copaDelRey, champions):
	return laLiga + copaDelRey + champions