Præsentation er lastning. Vent venligst

Præsentation er lastning. Vent venligst

Throw a die Read the current value of index Add 1 Return the new value to index IndexIndex Create an empty array to count the number of dice throws Initialize.

Lignende præsentationer


Præsentationer af emnet: "Throw a die Read the current value of index Add 1 Return the new value to index IndexIndex Create an empty array to count the number of dice throws Initialize."— Præsentationens transcript:

1 Throw a die Read the current value of index Add 1 Return the new value to index IndexIndex Create an empty array to count the number of dice throws Initialize to 0 Create an empty array to count the number of dice throws Initialize to 0 Show the results in a Waveform Graph For loop ++

2 Find a random index (x,y) Set the x,y value of the index to True Create an empty 5x5 array Initialize to False While loop Wait MS = 100ms Connect it to the Control Array Icon

3 Vent fra 0-10 sekunder Tænd LED lys Udlæs tid Tænd LED lys Udlæs tid Vent på brugertryk på knap (Hint: brug tomt while loop) Sluk LED lys Udlæs tid Sluk LED lys Udlæs tid Træk de to tider fra hinanden og vis dem


Download ppt "Throw a die Read the current value of index Add 1 Return the new value to index IndexIndex Create an empty array to count the number of dice throws Initialize."

Lignende præsentationer


Annoncer fra Google