Students will develop a simple workout app. The app should be able to do the following:
- First, a simple random number is to be output. This should be between 1 and 20.
- Then create a list of workout activities (e.g. jumps, push-ups, mini sprints, …).
- At the push of a button, it should appear how often you do these activities (e.g. do 7 push-ups)
- On the screen should also appear a button with which you can exit the app
Worksheet: Step by step to the workout app
Dear children,
the following worksheet will guide you through the development of your tournament app.
To do this, first open the App Inventor.
- Now open a new project “Workout App“
The app should be able to do the following:
- First, a simple random number is to be output. This should be between 1 and 20.
- Then creates a list of workout activities (e.g. stretch jumps, push-ups, mini sprints, …).
- At the push of a button, it should appear how often you do these activities (e.g. do 7 push-ups)
- On the screen should also appear a button with which you can exit the app
Have fun!
In the first step you design the screen again. It could look like this if you only want to output a random number:
For this, you need blocks to calculate the random number and to finish the app:
The next step is to create a list that contains about 5 different activities. Use the list element, here you can add as many activities as you can think of. And this is how the complete code could look like.
The screen now looks like this…
And now, let’s go! Have fun with your workout!
