Case 10: Finger-guessing game
Use the Smart Coding Kit to create a finger-guessing game
Set both the variables "i" and "k" as 0 and show the on start icon
Set the wireless group
While pressing button A or/and B, set the variable "k" as the equivalent number and send it to show the icon accordingly
After receiving the data, save the data as variable "i"
In the Forever block, judge the value of "i" and "k", if they are not 0, it means both the players give a “fist" The winner will be judged by the comparasion of "i" and "k" Set both the varibles "i" and "k" as 0 and be prepared for the next round
You can also download it direcly below:
Choose to give a "fist" through button A or/and B, the results will be given accordingly, the winner has a smile face and the loser has a cry face on the micro:bit.