A Challenge

Use the skills you’ve learned throughout the past lessons to make a game. If it’s too hard, don’t worry, you can skip this and come back anytime.

LeaderBoards

1st Place: None

2nd Place: None

3rd Place: None

Challenge Description

In this game, create a variable called health. Make it so each “turn” a random outcome happens and you can earn health or lose health based on your choice. If you run out of health you should lose. You can make the game end after a certain amount of turns (using a for loop) or make it endless. To make it endless, instead of using a for loop you can do the following:

While(True):
—-Your code here

Below is an example that you can use as a template. Note that any code on a line after the # symbol is called a comment and will not be run. Bonus: Add another variable such as energy, food and/or water

Selected Value: 10
From 1 to 10

2 thoughts on “A Challenge

Leave a Reply

Your email address will not be published. Required fields are marked *