Coding Moves 102

22 May 2022

Coding moves 102

This is the famous Nike Commerical that came out in the early 200 where indivudals were dribbling to the beat.

BTE Trainer Coding Game

Game: How do you play? First, we have to teach you the rules.

  • BTE Sequence = BTE Combo X Number of times the combo was done

  • The BTE Dribble Score has three different ways of calculation that is dependent on if the combo is a one, two, or three dribble sequence

    • BTE Dribble Score = (BTE dribble#) X Number of times the combo was done
    • BTE Dribble Score = (BTE dribble# + BTE dribble#) X Number of times the combo was done
    • BTE Dribble Score = (BTE dribble# + BTE dribble# + BTE dribble#) X Number of times the combo was done

Dribble Tree

  • BTE_Coding_Moves_Question
    • How many times does he do the BTE Combo 442 sequence and what is his BTE Dribble Score?
  • 442 x 4

We only code the BTE Combo to get the BTE Dribble Score. There are tradational dribbles, a full combo, and a BTE combo.

  • Dribbles = 4,2
    • Every individual dribble
  • Full Combo = 442
    • A combo of dribbles within the full sequence of a move
  • BTE Combo = 442
    • The 3 core attacking dribble normally at the end of the sequence to create a move

After watching the dribbler this is what I entered as my first line of code. I wanted to get this right and then think about the extra 4 dribble.

  • Code

Here are an example of each of the dribbles the dribbler did.

  • 4 Between the legs where the ball goes from one hand to the other with the ball landing between your legs exchanging hands
  • 2 Crossover is when you exchange hands with the ball in front of your body

Coding Sequence

Create a list

  • This is what a list looks like. The dribbler does 1 combo so we add that next into the brackets
  • Combo1 = []

Put your value into the list

  • 4(Between the legs) BTE combo
  • Combo1 = [442]

Multiply the list to get the exact amout of times the trainer does the move

  • He did the 442 BTE Combo 4 times so we multiplied the list times 4 to get our answer for the sequences
  • Combo1 = [442]*4
  • He did the combo 4 times so the combo should be printed 4 times
  • [442, 442, 442, 442]

Something is not quite right

  • He had another dribble at the end of the sequence I almost forgot about. In order to make it accurate there is one last step. Here is how you add the 4 below.
  • 442_4

Coding BTE Dribble Score

Here is the answer to coding the dribbler dribble score below.

Create a list

  • This is what a list looks like. The dribbler does 1 combo so we add that next into the brackets
  • Combo1 = []

Put your value into the list

  • He does a 3(In & Out dribble), 2(Crossover), 4(Between the legs) BTE combo
  • Combo1 = [4+4+2]

Multiply the list to get the exact amout of times the trainer does the move

  • He did the 324 BTE Combo 3 times perfectly so we multiply by that number
  • Combo1 = [4+4+2]*4
  • He did the 442 dribble 3 times so the combo should be printed 4 times
  • [10, 10, 10, 10)

Then you have to set everything to Combo1Total

  • Now we are totaling up the score
  • Combo1Total = Combo1 = [4+4+2]*4
  • print(Combo1)

Last you add up the totals through using Combo1Total

  • You use the sum() method to total everything up
  • You add the +4 because he had an additional dribble
  • sum(Combo1Total)+4

The dribbler did not mess up on his combo but added an extra dribble at the end that would not give him a perfect score.

  • 442_Done
  • Answer