Presentation is loading. Please wait.

Presentation is loading. Please wait.

Intro to Programming With Snap PII.

Similar presentations


Presentation on theme: "Intro to Programming With Snap PII."— Presentation transcript:

1 Intro to Programming With Snap PII

2 Warm Up: What is the difference between these 3?
count from 11 to 99 skips 20, 30, 40 ..etc count from 0 to 99 Counts from 1 to 99 skips 0, 10, 20, etc

3 Can you make one that counts from 100 down by 10s?
counts down from 100 to 0 by 10s (first number it assesses is 109 but 109 is NOT divisible by 10)

4 Make a page of Notes: What is modular arithmetic “Clock Math”?

5 The remainders start at 0 and increases by 1 each time, until the number reaches one less than the number we are dividing by. After that, the sequence repeats. By noticing this, we can visualize the modulo operator by using circles. We write 0 at the top of a circle and continuing clockwise writing integers 1, 2, ... up to one less than the modulus.

6 15 mod 12 = ___ 24 mod 12 = ____ 57 mod 12 = ____ 60 mod 12 = ____
9 15 mod 12 = ___ 24 mod 12 = ____ 57 mod 12 = ____ mod 12 = ____ 3

7 3 3 2 2 18 18

8 Game on Kahn Academy org/computing/computer- science/cryptography/moda rithmetic/p/modulo- challenge

9 Practice Questions (just do top 4 today)
Sprite is in the middle of the scripting area. Points to the right (90°). Screen is cleared When the green flag is clicked, the sprite will follow the mouse. Spiraling triangle thing… If sprite is NOT facing 90 degrees, it will turn until it faces 90 degrees, 1 degree and 1 step at a time.

10 Assignment 2: Maze Projects with a Partner Big Idea: Abstractions and Creativity

11 EXs of a Basic Maze

12

13

14

15 CSP Maze Partner Project 

16 OR http://tinyurl.com/APCPSrubric
OR

17

18

19 Maze Game Maze resources and these following slides (PPT, PDF) are available at: mazeGame

20 Help Getting Started Use blocks to begin your game and accomplish the following: enable your game to start with pressing of green flag move sprite to starting point move sprite back if he touches a wall set use of arrow keys accomplish the red square for winning maze “red box” target (if your target is different; make adjustments)

21 Maze Resources maze-resources.zip (

22 Step 1 Set up the sprite (use your own), stage costumes (make your own) and sound

23 Step 2 Write the the program script for the Sprite
enable your game to start with pressing of green flag move sprite to starting point move sprite back if he touches a wall set use of arrow keys accomplish the red square for winning maze “red box” target (if your target is different; make adjustments)

24 Step 3 Write the the program script for the Stage

25 SNAP! Assigns direction as follows:
***Locations on the stage (the white rectangle where sprites perform their scripts) are specified by (x,y) coordinates. The center of the stage is (0, 0). The left edge is x = -240; the right edge is x = 240. The bottom is y = -180 The top is y = 180

26 Debugging Advice

27 Debugging Cont.

28 Paired Programing At the keyboard
Driver Navigator At the keyboard Implements the next task provided by the navigator. Gives future tasks to the navigator to track. Answers navigators questions. Keeps track of the big picture. Responsible for directing the flow of work to a specific conclusion. Reviews code. Keeps track of tasks identified by the driver so they can focus on coding. Ensures that best practices are followed. Track potential code improvements. Asks questions about the driver’s implementation


Download ppt "Intro to Programming With Snap PII."

Similar presentations


Ads by Google