TORONTO KIDS COMPUTER CLUB | Aurora Tuesday 18:30 Python Practice – 08 20.10.06.
18438
post-template-default,single,single-post,postid-18438,single-format-standard,ajax_fade,page_not_loaded,,qode-theme-ver-7.6.2,wpb-js-composer js-comp-ver-6.8.0,vc_responsive

Aurora Tuesday 18:30 Python Practice – 08 20.10.06.

09 Oct Aurora Tuesday 18:30 Python Practice – 08 20.10.06.

Question 1:
Create a loop between 1 to 20.

  • Print “fizz” if the number is divisible by 3
  • Print “bizz” if the number is divisible by 5
  • Print “fizzbizz” if a number is divisible by both 3 and 5.
  • Otherwise, print the number itself.

Question 2:
Continue modify the program we made in the class, so that:

  • after your robot hit the enemy, if enemy’s hp is lower or equal to 0, use msgbox to display message ‘You win’, and the whole program finish.
  • otherwise, it will be the enemy’s turn to strike you back. Enemy can only use gun to fire and cause damage between 50-80.
  • after enemy’s turn, if your hp is lower or equal to 0, use msgbox to display message ‘you lose’, and the while program finish.
No Comments

Sorry, the comment form is closed at this time.