## If/else syntax debug

While making a game, your partner, Greg, decided to create a function to check if the user is still alive called `checkAlive`/`CheckAlive`/`check_alive`. Unfortunately, Greg made some errors while creating the function.

`checkAlive`/`CheckAlive`/`check_alive` should return true if the player's health is greater than 0 or false if it is 0 or below. 

```if-not:csharp
The function receives one parameter `health` which will always be a whole number between -10 and 10.
```

Difficulty: EASY
Starter code: def check_alive(health):
	

Solutions:
def check_alive(health):
	if health <= 0:
		return False
	else:
		return True
print(check_alive(0))


def check_alive(health: int):
	return health > 0


def check_alive(health):
	if health < 0:
		return False
	elif health == 0:
		return False
	else:
		return True


def check_alive(health):
	if health in range(-10, 0):
		return False
	elif health == 0:
		return False
	else:
		return True


def check_alive(check_alive):
	x = check_alive
	if x > 0:
		return True
	else:
		return False


def check_alive(health):
	if health <= 0:
		return False
	else:
		return True
check_alive(2)


def check_alive(health):
	if -10 <= health <= 0:
		return False
	elif 0 < health <= 10:
		return True


def check_alive(health):
	if health <= 0:
		return bool()
	else:
		return bool(True)


def check_alive(health):
	return health > 0


check_alive = 0 .__lt__


def check_alive(health):
	return (lambda x: True if x > 0 else False)(health)


def check_alive(health):
	if health <= 0 or health == 0:
		return False
	else:
		return True


def check_alive(health):
	return False if health < 1 else True


health = list(range(-10, 10))

def check_alive(health):
	if health > 0:
		return True
	else:
		return False


def check_alive(health):
	-10 < health < 10
	if health <= 0:
		return False
	else:
		return True


import unittest

def check_alive(health):
	return True if health > 0 else False

class TestCheckAlive(unittest.TestCase):

	def test_should_return_true_when_health_is_greater_than_0(self):
		self.assertEqual(check_alive(health=1), True)

	def test_should_return_false_when_health_is_0(self):
		self.assertEqual(check_alive(health=0), False)

	def test_should_return_false_when_health_is_negative_int(self):
		self.assertEqual(check_alive(health=-1), False)


check_alive = lambda n: n > 0


def check_alive2(func):

	def wrapper(*args, **kwargs):
		result = func(*args, **kwargs)
		return result
	return wrapper

@check_alive2
def check_alive(health):
	return True if health >= 1 else False


def check_alive(health):
	if health >= 1:
		return True
	if health <= 0:
		return False


def check_alive(health):
	val = True
	if health <= 10 and health >= -10:
		if health > 0:
			return True
		else:
			return False
	else:
		return 'Nombre non effectif'


def check_alive(health):
	if -11 < health < 1:
		return False
	elif 0 < health < 11:
		return True


def check_alive(health):
	if health <= 10 or health >= -10:
		if health > 0:
			return True
		else:
			return False
		return Error


def check_alive(health):
	if health <= 0 and health >= -10:
		return False
	elif health > 0 and health <= 10:
		return True
	else:
		return 'Impossible!'


1 == 'true'
0 == 'false'

def check_alive(health):
	if health <= 0:
		return 0
	else:
		return 1


def check_alive(health):
	if health <= 0:
		return 1 != 1
	else:
		return 1 == 1
print(check_alive(4))


def check_alive(health):
	alive = 0
	if health > 0:
		alive = 1
	return alive


def check_alive(health: float):
	if health <= 0:
		return False
	else:
		return True


def check_alive(health):
	if health == 0:
		return False
	if health < 10 and health > 0 or (health < 0 and health < -10):
		return True
	else:
		return False


def check_alive(h):
	return True if h > 0 else False


def check_alive(health):
	return health >= 1 and health <= 10


def check_alive(health):
	if health <= 0 and health >= -10:
		return False
	elif health > 0 and health <= 10:
		return True
	else:
		print('Put a correct number')


def check_alive(h):
	return h > 0


def check_alive(health):
	Heal = True
	if health <= 0:
		Heal = False
	return Heal


def check_alive(health):
	if health <= 0:
		return False
	else:
		return True
	return health
check_alive(9)


def check_alive(health):
	return health > 0 and True


def check_alive(health):
	alive = True
	if health <= 0:
		alive = False
	return alive


def check_alive(health):
	x = True
	y = False
	if health < 1:
		return y
	else:
		return x


def check_alive(health):
	check = health > 0
	return check


def check_alive(health):
	if health >= 0 and health != 0:
		return True
	else:
		return False


def check_alive(health):
	if health <= 0:
		result = False
	else:
		result = True
	return result


def check_alive(hp):
	if hp <= 0:
		return False
	else:
		return True
test = check_alive(1)


def check_alive(health):
	if health <= 0:
		return health != health
	else:
		return health == health


def check_alive(health):
	if health <= 0 or health is None:
		return False
	elif health > 0:
		return True


def check_alive(health):
	return health > 0 if health in range(-10, 10) else False