beanz Magazine October 2017

Page 1

Kids, Code, and Computer Science

d r o w s s a P r u ? o e Y f s a I S Y L L How to Create a A E R Super-Secure Password

Making Sense of EV3 Robots October 2017

$6.00 $6.00 USD

What Do Pigpens Have to Do With Secret Codes? Put Some STEAM in the Season! The beanz Holiday Gift Guide Is Here


beanz magazine October 2017 : Volume 5 Issue 2 Issue 32 (online) & 17 (print) ISSN: 2573-3966 (online) ISSN: 2573-3958 (print) beanz Magazine© is published bimonthly, six times a year, online at https://beanzmag.com and in print. A print + online magazine subscription includes online access to all articles, with links to let you explore topics in more detail. SUBSCRIBE: visit https://beanzmag. com/subscribe or email us for checks/ invoices. We’re also available through EBSCO, Discount Magazine, WT Cox, Magazine PTP, and many other subscription services. ONLINE MAGAZINE ACCESS: send your email address to hello@beanzmag.com and we’ll set you up. Published by Owl Hill Media, LLC 378 Eastwood Rd, Woodmere, NY 11598 Email: hello@beanzmag.com Phone: (646) 553-3390

Hello! Welcome to the second issue with our new name! How the magazine is created has changed, in many ways. I still work with the writers to pull stories together, then the designer takes these and disappears for awhile. When she comes back, the stories are laid out with lots of engaging images she’s found, a few doodles that talk, and a fun reading experience as we proof each page. Hopefully you’ll also enjoy reading this issue. This time we stumbled on an animal theme. Years ago, we did articles about ancient puzzles and I wanted to bring one back, Pigeons on the Stairs. Simon happened to write about Pigpen Ciphers. And after a discussion I had with a programmer about how they use CamelCase, of course I had to write about it! In addition to animals, this issue has projects you can work on — Scratch, micro:bit, Lego EV3, Minecraft, coding—plus some neat but mysterious things like a language about color (Piet) and the Uncanny Valley. And ideas for creating safe passwords. It’s also almost time for the holidays. We’ve put together a massive list of STEAM ideas, from books to robots, apps to board games, and card games to electronics. There’s also a few more at our free list of STEAM tools sorted by grade: http://beanzmag.com/ steam-tools. Enjoy this issue and we’ll see you in December!

POSTMASTER: Send address changes to Owl Hill Media, LLC, 378 Eastwood Rd, Woodmere, NY 11598. Periodicals postage paid at Woodmere, NY and other mailing offices Copyright Owl Hill Media, LLC with all rights reserved except as noted. Flickr images are copyright their creators, as noted with each story both online and in print. Publisher/Editor/Webmaster: Tim Slavin Staff Writers: Simon Batt, Patricia Foster, Charles Hanks, Clarissa Littler, Jennifer Newell, Les Pounder, Paul Seal, Erin Winnick, Tim Slavin Contributors: David Dodge, Jay Silver, Jeremy Kubica, Colleen Graves, Daniel Fenjves, Ali Hagen, Emeline Swanson, Jean-Francois Nguyen, Madeleine Slavin Copy Editor: Madeleine Slavin Copy Editor: Derek Lanuto Art Director: Kelley Lanuto COVER IMAGE: NADIA HATOUM, FLICKR

Tim Slavin Publisher beanz Magazine beanz magazine (as Kids, Code, and Computer Science magazine, our earlier title) is a winner of Parents’ Choice, Tillywig,

Our Mission

and Academics’ Choice awards: https://beanzmag.com/awards

beanz magazine is a bi-monthly online and print magazine about learning to code, computer science, and how we use technology in our daily lives. The magazine includes hard-to-find information, for example, a list of 40+ programming languages for education, coding schools, summer tech camps, and more. While the magazine is written to help kids ages 8 and older learn about programming and computer science, many readers and subscribers are parents, teachers, and librarians who use the articles to learn alongside their young kids, students, or library patrons. The magazine strives to provide easy to understand how-to information, with a bit of quirky fun. Subscribers support the magazine. There is no advertising to distract readers. The magazine explores these topics: Basics of programming and where to learn more, Problem solving and collaboration, Mathematical foundations of computing and computer science, Computational thinking, Recognizing and selecting computer devices, Community, global, and ethical impacts of technology.


contents

advanced

beginner

intermediate

October 2017

2 16 6 8 10 11 12 13

Concepts The Uncanny Valley Secret Codes Cover Story Pigpen Ciphers Make It An Electrifying Idea! Coding Cat and Mouse Coding CamelCase Language of the Month Piet: A Language of Colors

tidbitz

5 Space Art 5 Here Be Dragons

Cover Story

Robotics Makes Sense to Me!

Puzzles Pigeons on the Stairs

14 15 16 18 20 21 22 The

beanz

STEAM Gift Guide 2017 Cover Story

Scratch Charred Cats Minecraft The Tool Box Puzzles Pigeons On the Stairs Circuits Thirsty Plants Love Micro:bit! b safe online Cover Story Create a Secure Password Show and Tell Planet Labs

28 ParentTeacher Corner Overcoming Common Challenges in the CS Classroom


Robotics

2

e s n e S s e k a M ! e M to

BY JENNIFER NEWELL

In order to navigate through the world, people must take information from outside of our bodies and process it within. How do we do this? For the most part, we use our five basic senses: touch, smell, taste, sight, and sound. Without our senses we would bump into walls, fall down stairwells, eat food that our bodies cannot process, and have no way to communicate with one another. Robots are made of synthetic materials that do not have any built-in senses. So how can robots navigate through their environments? Fortunately, there are hundreds, if not thousands, of sensors that we can buy for our robots to help them detect where they are, what’s around them, and to communicate with each other as well as with us humans.

EV3 Color Sensor

EV3 Sensors

The Lego EV3 robotics kit comes with three separate sensors as well as sensors built into the servo motors. We can use EV3 legos to build all sorts of robots. Depending on what we need our robot to accomplish, we can choose what sensors to include on it. A fun beginning robotic project is to build a robot that follows a given path. If we know the path in advance we can program our robot to travel forward a certain distance, turn a certain number of degrees and so on. But what if we want to generalize the process so that we can place our robot on any path and be confident that the robot will not stray? Color Sensor

Every color reflects a certain amount of light. The EV3 color sensor takes in that light, converts it to a number, and uses it to ensure the robot never strays off a given path. For example, we could draw any path in black ink on a white sheet of paper and use EV3 legos to build any style robot we like. So long as we attach the color sensor on part of the robot such that it is always within approximately one centimeter of the paper, it will read in the amount of light that is reflected below it. When the color sensor is above the black path, it will read in the amount of light reflected by black, and convert that amount into a number. If the path curves but the robot travels on straight ahead, the color sensor will end up over the white surface, and read in the amount of light reflected Continued

EV3 Infrared Sensor


3

EV3 Flipper Sumobot/ Battlebot with Infrared Sensor

DAVID LUDERS, FLICKR


4

Continued

by white. We can program our robot to move a certain way if it sees black, and another way if it sees white. In this way we can guarantee that our robot always stays on the black path. When we lift the color sensor more than a couple centimeters from a surface, we notice the amount of light it reads in drops to almost zero. Can you think of how to use this drop in value to program a robot to back up and turn around when it reaches a precipice such as the edge of a table or a stair case? Infrared Sensor

An infrared sensor is a bit like a color sensor in that it also detects light. However, it emits its own infrared light and measures the distance between itself and an obstacle by detecting what percent of its infrared light gets reflected back. If little or none of its light is reflected back then the robot might want to continue forging ahead. On the other hand, if too high a percent of its light comes back to it, the robot is likely near an obstacle and may need to reverse directions to avoid collision.

EV3 Infrared Control

Touch Sensor

Additional Sensors

Though the home edition of the EV3 robot set includes three sensors, both a gyro sensor and an ultrasonic sensor are available for purchase separately, or as part of the EV3 Education set. The gyroscopic sensor is used to detect rotational acceleration. In other words, it calculates the angle between itself and the ground to tell the robot how quickly it is falling or tipping. In turn, this information can be used to program a robot to continually determine the angle between itself and the ground and correct itself if it is off balance. Outside of the EV3 set, gyroscopic sensors are critical for keeping contraptions such as the Segway balanced, as well as for building accurate navigation systems. Ultrasonic sensors are another real world device with an EV3 version. They the idea behind them is similar to that behind the infrared sensor, except an ultrasonic sensor emits a soundwaves instead of light. The sensor measures the time it takes for its high-frequency soundwaves to bounce back to it, and based on that time, calculates the distance between itself and an obstacle. Outside of EV3 robotics, ultrasonic sensors are used in a wide range of applications from determining the distance between a crop and boom on agricultural machinery, to measuring proximity between cars in vehicles such as the Tesla. b

Following a Black Line

DAVID LUDERS, FLICKR

The EV3 touch sensor is basically a button. It can be programmed so that when it is not pushed the robot behaves a certain way, and when it is pushed the robot does something different. By attaching a bumper to the touch sensor, we can expand the amount of surface used to trigger the button. If the bumper touches a wall or other obstacle in front of it, it changes state from “zero” to “one”. This allows us to program our robot to continue moving forward when the touch sensor reads “zero” and to make a noise or back up and turn around when it reads “one”.

Underside of EV3 Fllying Box Turtle Showing Two Color Sensors

For more on EV3 robots, check out the link on the back cover of this issue.


tidbitz NASA, ESA, AND G. BACON (STSCI), FLICKR

Space Art

tidbitz

5

Astronomers find habitable planets with their telescopes, but how do you know what these planets and solar systems actually look like? A visualization scientist at NASA translates data from these planets into pictures we can recognize as planets and stars. We’ll never know for certain if these pictures match the reality, but they give us a way to understand what distant habitable planets might look like. When planets were discovered around a star called TRAPPIST-1, NASA visualization scientist Robert Hurt got the assignment to create visual images. TRAPPIST-1 is a dim red star about 40 light years from us and has seven earth-sized planets that rotate closely around it. Hurt and a colleague, Tim Pyle, a multimedia producer, created a series of amazing photorealistic images of the TRAPPIST-1 planets. Their images were based on data extracted from telescopes. This is called space art. Early on, scientists wanted to convert their data into images to better understand it. And space programs like NASA realized visual images got the public excited and supportive of their missions. Artists imagine what alien worlds look like based on real data, for example, figuring out at which angle a planet might be relative to its sun and the sky color based on the chemistry of the planet’s atmosphere. So the next time you’re outdoors at night and look up to see the moon, imagine what it might look like to be on a planet flying around the TRAPPIST-1 star. Could you see the other six planets? Maybe! b

—Adapted from the article by Pat Brennan from NASA’s Jet Propulsion Laboratory https://www.jpl.nasa.gov/news/news.php?feature=6868, https://www.jpl.nasa.gov/ spaceimages/details.php?id=PIA21422

Here Be Dragons

In New York City, 8.5 million people live and work in 304 square miles of land. Imagine all the gas, electrical, trains, sewer, water, and other things that make it possible for people to live, eat, work, and play there. Surprisingly, there isn’t one single map that details where everything is located. Parts of the city are like fairy tale maps with “here be dragons” on it. September 11, 2001 and Hurricane Sandy in 2012 made clear the city needs a single map that shows everything so people can plan and avoid disasters like breaking gas lines and hurting people. So New York City is developing a single map using Global Information Systems (GIS). The link below will bring you to the article, where you can learn how the depth of pieces of the city is determined, and other interesting details. b

MTA NEW YORK CITY TRANSIT/ MARC HERMANN/FLICKR

https://www.bloomberg.com/news/ features/2017-08-10/nobody-knows-what-liesbeneath-new-york-city


Concepts

6

tk

The Uncanny Valley BY TIM SLAVIN

When you play a video game that is extremely realistic, every detail in place, or see a picture of a really lifelike robot, what’s your reaction? Most likely your response is caution or rejection. Or you feel uneasy, creeped out. Turns out humans have a primitive response to images and experiences that are too human but not human. We can

lose ourselves in cartoons, video games with characters who clearly are not human, and movies with lots of special effects. But seeing someone near human makes us stop. We love Wall-E the robot but fear the Terminator (or at least Arnold Schwarzenegger). This effect is called the Uncanny Valley. It could be as simple as confusion about what is real and what is fake. Or it could be a primitive fight or flight

response our ancestors developed tens of thousands of years ago, a way to survive dangerous situations. While video games have made the Uncanny Valley ubiquitous in the past few decades, how people respond to uncanny situations, and what makes an uncanny situation, has been debated for centuries. One idea is that the more people know what is around them,


7

BARBARA TROTTA, FLICKR

the less likely something extremely lifelike will make them pause. It’s the surprise that causes hesitation and rejection. The word uncanny means something beyond our familiar knowledge or perceptions. Another possible reason we reject characters and robots we see as too human might be they remind us of our mortality, the one disadvantage we have compared to robots. Presumably robots will outlive us. And robots pretend to

be human but without all the joy and suffering humans go through. Maybe we are jealous! The term Uncanny Valley is credited to Dr. Masahiro Mori, who wrote about robots, animatronics, and animation that tries to be lifelike but fails. Dr. Mori wanted to understand the reasons they failed. A 2007 study of 75 virtual characters, from Mickey Mouse to Lara Croft, found people rated lowest the character that was the

most human. While the Uncanny Valley could be a problem to solve for robotics, a recent BBC article suggests video games, with their many humanlike characters, are eroding the Uncanny Valley effect. The more people play video games, the more they get used to uncannily human characters. What do you think? Has playing video games made the strange “not so strange� to you? b


Secret Codes

8

e h p i C n e p g Pi

BY SIMON BATT

In the last issue, we explored the simple substitution cipher to create a basic yet efficient code. This issue, let’s explore the Pigpen Cipher. This cipher uses alien-like symbols to share messages. The meaningless and bizarre shapes are actually transmitting a code! The Pigpen Cipher has a strange name, but there’s a reason behind it. The idea is that you assign each letter of the alphabet to a specific shaped bracket, or ‘pigpen’. When you write your secret message, instead of writing normal letters, you instead write the bracket in which each letter ‘lives’. Let’s try it out. First, draw out 26 different ‘pigpens’ for your code, and assign a letter to each one. Make sure each pigpen looks different from the rest. To make things easier, you can repeat the basic shape of a pen but add a symbol or a marker to differentiate it from the others. Here’s an example of a basic pigpen cipher:

Remember you don’t have to follow the above example if you don’t want to! If you can think of more interesting shapes to use, feel free to invent your own. Just remember to ensure no two pens look identical. Now that we have our cipher, it’s time to make a coded message. Let’s keep this first one simple: let’s say we want to transmit the word “ANT”. Locate each letter and note the shape of the ‘pigpen’ that’s around it. For instance, A is inside a backwards L, N is inside a box with a dot near the bottom, and T is in an sideways V shape.

Once you’ve found in which pigpen the letter is, you write your message down by drawing the shape of each pigpen, rather than the letter itself. If you’re using dots like I am, make sure that you don’t forget to add them into your code, or else things get very confusing! To spell ANT, we’ll write the word like this:

When someone with the code’s key receives your message, all they have to do is look for the pigpens in the cipher and note the letter that’s within it. They’ll see the backwards L and write A, then the box with a dot for the N, and a sideways V for the T. Success! Our message has been delivered! In a way, this code is about making an alternate alphabet and making messages by translating English words through it. As such, it makes it quite easy to crack, but it has the added benefit of not looking like regular letters at all. Nobody will suspect you’re sending messages. Disguise them as a decorative pattern, hide them in images, make them look like random scribbles…the possibilities are endless! Now it’s your turn. Let’s pretend we’re going to talk to a friend about meeting up later, and we both have the cipher key to encrypt and decrypt messages. Using the cipher we defined above, how would you write the following sentence? WHEN SHALL WE MEET Once you send your message, your friend replies with the following message:

What is your friend trying to say? For the answers, look on page 16. For more about Pigpen ciphers, check out the links on the back cover of this issue. b


s r e

9

a t o g I’ve e g a s s me u! o y r fo JUSTIN LEONARD, FLICKR


BY ERIN WINNICK

An Electrifying Idea! In sewing, thread is an essential tool. It adds decorative elements, as well as acts the elements that can secure all of your pieces together. But did you know it can have another use? Thread can run electricity through your clothing and fabric projects! There is a special kind of thread called conductive thread that can turn your fabric into an e-textile. This thread can be made of silver or stainless steel, and comes on a small bobbin just like normal thread. By sewing conductive thread into your projects, you can make things like touchscreen-compatible gloves, or send power to LED lights on a shirt! An electric circuit is a connected system, moving power between a battery and the items that need to be powered. Conductive thread

can serve as that bridge in sewing projects, allowing your circuits to become flexible and sewable. Order conductive thread from Adafruit. Get 76 feet (23 meters) for $5.95, enough for some fun, technology-based sewing projects. Test this thread with a quick project that will turn your gloves into smartphone-compatible gloves. In order for phone touchscreens to work, they need to have contact with your finger. This is because they use something called a capactive touchscreen which works when your finger touches it and completes its circuit. Therefore, if we add conductive thread to the outside of our gloves, the thread will contact both our skin and the phone, making the gloves touchscreen compatible.

SENIJU, FLICKR

Make It

10

Smartphone Gloves Materials needed: • Conductive thread • Needle • Knitted gloves • Clear nail polish 1. Thread your needle with a 8 inch length of conductive thread. 2. Starting from the inside of the thumb section of your glove, bring the needle up through a section of the pad of the glove’s thumb finger. Leave about 1.5 inches extending straight into the glove thumb. 3. Once the needle is on the outside of the glove, bring it back inside about 1/8 inch down. We are creating a small surface area where your finger can contact the phone and activate it. 4. Bring the needle back out of the thumb again and continue this process until you have secured the thread in place. 5. You can use a small amount of clear nail polish to seal the ends of your conductive thread, and to secure them in place on the inside of the glove. Do not cover all of the thread as this will limit its conductive nature. 6. Repeat this process on all of the fingers of the glove. 7. Test out your new gloves on a smart phone! BY_YOUR, FLICKR

Want to learn more about adding LEDs to your projects using conductive thread? Check out the links on the back cover of this issue.

b


11

Cat and Mouse For years, we’ve watched the mouse cursor zoom around the screen. Let’s change that by creating a JavaScript cat to chase the mouse! Open your browser and navigate to http://jsfiddle.net. See how the screen is separated into four different boxes? Each box accepts code from a different language: HTML, CSS, and JavaScript. Next, in the bottom left-hand editor, click on the little gray gear next to ‘JAVASCRIPT’. Click on the box under ‘Frameworks & Extensions’ Select ‘jQuery 3.2.1’ jQuery is a extension of JavaScript. It can move and modify the elements of a webpage. HTML

HTML can be seen as the ‘bones’ of a webpage. In the top left-hand editor, type: <div id=“cat”> An html ‘div’ is a type of container. This one’s id, or ‘name’, is ‘cat’. Inside the tags we’ll put the ASCII art for our JavaScript kitten. =^.^= See how the ‘=‘ are whiskers, and the ‘^’ are ears, and the ‘.’ is a nose? ASCII art is a way of making pictures using letters and other typed symbols. </div> Every ‘opening’ HTML tag needs

a matching ‘closing’ HTML tag. It’s like putting a lid on a container. CSS

If HTML is the bones, then CSS is the ‘skin’. It wraps around the bones and makes everything look pretty. In the top right-hand editor, type: #cat { position:absolute; } The ‘#cat’ references the container we’ve just created The ‘position’ property controls the position of its container. ‘Absolute’ means that the div will be positioned relative to another element. In this case, we’re moving our div based on the mouse’s position. JAVASCRIPT

JavaScript will be the ‘muscles’ of our webpage. It makes things move! In the bottom left-hand editor, type: $(document). mousemove(function(mouse){ $(“#cat”).stop(). animate({left:mouse.pageX, top:mouse.pageY}); }); $(document).mousemove( X ); The ‘$’ in JavaScript means that jQuery is being used behind the scenes. This piece of code registers an event handler for mouse movements. That’s a fancy way of saying ‘the browser window now pays attention when the mouse

Coding

BY PATRICIA FOSTER

ROXANNE READY, FLICKR

moves around’. The ‘X’ dictates what the browser does when it detects a moving mouse. Don’t forget to end this statement with a semi-colon! function(mouse) { Y } This piece of code replaces the above ‘X’. It translates to: ‘If you see the user moving the mouse, do the action described in Y.’ $(“#cat”).stop().animate( Z ) This piece of code replaces the ‘Y’. It’s what actually moves our cat. The first part, $(“#cat”), uses jQuery to locate the ‘#cat’ div on the screen. If the cat is running around, the ‘.stop()’ forces it to freeze in its tracks, while ‘.animate( Z )’ tells the cat where to run next. {left: mouse.pageX, top: mouse. pageY} This piece of code replaces the ‘Z’. It tells the cat where to find the mouse. The ‘left’ and ‘top’ properties determine the cat’s position. Here, they’re matched up to the mouse’s ‘left’ and ‘top’,or X and Y, coordinates. The result: the cat zooms toward the mouse. Hit the ‘Run’ button at the top of the screen. The bottom right-hand console contains the output of the program. Move your cursor and watch the cat chase your mouse! Psst! If the cat isn’t moving but the code is correct, you might have forgotten to add jQuery. b


Coding

12

BY TIM SLAVIN

Which do you think is easier to read, arrsomebigcollectionofdata or arrSomeBigCollectionOfData? If you read software code long enough, you will notice uppercase and lowercase letters are everywhere. What gives? It’s not a secret code, exactly, and there’s no mysterious list of when to use capital letters and when not. Instead, it’s an example of how software programmers take a technical problem—in this case, how to make code readable— and find a fun way to describe the solution. The use of capitals and lowercase letters is called

CamelCase with the capital letters as the humps in the camel. It’s also been called BumpyCaps and HumpBack and a few other words. The most boring is the technical term, medial capitals. For some reason, CamelCase has stuck despite many cases where there are far more capital letters used than humps in a camel. There’s also lower CamelCase which begins with a lowercase letter and upper CamelCase which begins with a capital letter. The rules for how to use CamelCase are set by whoever decides the overall programming standards for a project. Sometimes

those standards are defined by the creators of the language used. But mostly the rules for CamelCase tend to be lower CamelCase for variable names and upper CamelCase for functions, methods, and other blocks of code. In some cases, lower CamelCase also is used to indicate functions and methods that can be used anywhere in the code (public) and upper CamelCase for code blocks that can only be used within another code block (private). Regardless of the rules, using lower and uppercase letters helps programmers understand the role a name has within their software code. For more great information on CamelCase, check out the link on the back cover of this issue. b

s i t a h ? e W s a C l e m a C NIGEL SWALES, FLICKR


Piet: A Language of Colors Our languages are restricted by how we speak and interpret symbols. But a computer doesn’t need to know if the symbols are pronounceable or make sense to a human ear or eye. Welcome to the world of esoteric languages! Esoteric programming languages, sometimes called esolangs, push the boundaries of what it even means to be a language. They can consist of nothing but emoji, or be made up entirely of whitespace! Piet is an esolang created by David Morgan-Mar in which programs are pictures made up of regions of solid colors that resemble the art of Piet Mondrian. The specification for Piet is available on its website: http:// www.dangermouse.net/esoteric/ piet.html. There’s also an excellent Piet tutorial at http://homepages. vub.ac.be/~diddesen/piet/index. html. When getting started, take a look at the online interpreter

found at http://zobier.net/piet/. When the program consists solely of solid color, how does the program know what to do? Piet chooses commands based not on color, but on changes in color. Every time the interpreter moves from one color to another, a command will be run. Piet uses just 18 specific colors: the light, dark, and medium versions of red, yellow, green, cyan, blue, and magenta. The allowed colors are given in hexidecimal form. A good site for understanding hex forms of colors is http://www.color-hex.com/. There are many possible programs that all do the same thing. For example, both of the eample programs at lower left add 2 and 2 then print it out. Using the online interpreter, if you select a color it shows you what color to choose next to get the command you want. The commands available in Piet are pretty limited. You work with stacks. Picture a stack of books. You can either put another book on top, or take one off. Computer scientists call putting something on the stack “pushing” and taking the top thing off the stack “popping”. In Piet you can push numbers onto the stack, pop them off the stack, do arithmetic with numbers on the stack, read and print out simple data and manipulate which color block is chosen next. It may not sound like it, but that’s powerful enough to write any program you want. For more great information on Piet and esolangs, check out the link on the back cover of this issue. b PIET MONDRIAN, “BROADWAY BOOGIE WOOGIE:, COLLECTION OF THE MUSEUM OF MODERN ART

Language of the Month

13

BY CLARISSA LITTLER


Scratch

14

BY CLARISSA LITTLER

For info on Scratch go to https://scratch.mit.edu

Charred Cats Let’s build a small, simple game in Scratch, based off of the ancient DOS game Scorched Earth. The game: Charred Cats. How it plays: a player and a computer take turns firing at each other. The first one to hit the other player with a projectile wins. You control the angle at which you fire and how hard you lob your projectile, but that’s all. Projectiles that don’t hit a player blow up and destroy the terrain, opening up new ways to fire at each other. In our first version, you can’t blow yourself up. Control the angle of firing with left and right arrow keys and the power of the shot with the up and down arrows. You fire by hitting the spacebar. Clicking on the green flag will reset the game.

vertical velocity from the angle and power the projectile is fired at. You account for gravity by having the vertical velocity decrease every step. If not, you copy the code from the partial version called “Charred Cats—movement code” or read the tutorials on the physics of projectiles. When the projectile hits a target it will blow up the terrain! You can “destroy” the terrain by covering it up with white. Do that by switching the projectile to a different costume and using the stamp command. Also, the code for resetting the

Piece 2: Coding the Projectiles

Every time a projectile is fired you’re making a clone of the sprite you’re coding in this step. You’ll want to make two different projectile sprites: one for the player-controlled sprite and one for the opponent. If you’re comfortable with the idea of sine and cosine functions or you’ve had some basic physics, then you should be able to code the movement of the projectiles by figuring out the horizontal and

Piece 5: Taking Turns

Maybe you’ve noticed that you can spam the firing button while your opponent is firing. That’s not very fair! This may be a war, but you still have to take turns. Your opponent is already waiting until you fire before taking a shot, so you just have to do the same. You do that by modifying the code for when you press the spacebar. Rather than always firing, you need to have it fire if the enemy’s projectile has landed. You’ll need a variable to keep track of whether you’re ready to fire. This variable will change based on a message the player sprite receives, and the computer projectile is going to send a message when it lands. Piece 6: Ending the Game

Piece 1: Building the Scene

To create our terrain and place our sprites, go down underneath Stage and select the paintbrush icon. I chose solid green for the backdrop, and with the eraser I erased out a hilly stage with two flat spots for our two sprites.

when to fire. You’ll need it to listen for a message that tells it to fire. It can fire by randomly choosing an angle and power and then creating a clone.

terrain at the end of the game belongs in these sprites. Piece 3: Firing Your Shots

Write the user interface code. You’ll need an event for each keyboard press. I chose • up key for increasing power • down key for decreasing power • left key for increasing angle • right key for decreasing angle • space bar for firing We already said that projectiles are all going to be clones of the base projectile sprites. So what block do you need to use to fire a projectile? Piece 4: Coding Your Opponent

Your opponent needs to know

You have to detect whether the player or computer sprite is hit by the opponent’s projectile. Do this by changing the projectile’s code so it checks to see if it hits the terrain or the enemy sprite before blowing up. If it hits the terrain and blows up, you’ll need to check and see if the explosion costume is big enough to hit the sprite. The projectile then sends a message saying who won. You should have the sprite who won say that they won and then “stop” the game. There’s a lot more to this, and you can find it by checking out the link on the back cover. You’ll see more info on each of the steps, as well as cool stuff to add to your games. b


For info on Minecraft go to https://minecraft.net

The Tool Box Last issue, we explored how to purchase and download Minecraft. Perhaps by now you’ve hopped into the gigantic world of Minecraft. Where do you go from here? Although adventure is part of the game, confusion shouldn’t be! So familiarize yourself with making simple tools, with which you can start to work out what you’d like to do in Minecraft. First, get some wood. Find a tree and hold down left-click on its trunk. Your character will begin punching the trunk, which will begin to crack. Once it’s fully cracked, it will explode and turn into a block of wood you can pick up. Pick up this block and press the I key. You should see the block in your inventory. Click and drag the block into the four squares to the right of your character in the inventory, labelled ‘Crafting’. In the box to the right of the crafting panel, 4 plank blocks will appear.

on the floor to place it. You now have a crafting table! If you right-click the table, you’ll notice you have a 3x3 area to craft with, rather than the measly 2x2 one in your inventory. We’re going to use this extra space to make some really good tools. Start by making two sticks. Do this by placing one plank above another in your inventory crafting or table. Then, make this pattern on the table:

Click the plank blocks to complete the crafting, then place one plank block in each spot of the crafting panel. This time, a crafting table should appear in the crafting result.

The pickaxe mines stone faster, the shovel helps digging through dirt, the hoe allows you to make farmland, and the sword is for protection against monsters. Make sure you build the sword before night time comes—that’s when all the monsters come out to get you! Using these tools, you can easily get the materials needed to build a basic house. Get some wood (using your axe) or stone (using your pick). Once you have a good hoard, put the wood and/or stone blocks onto your hotbar, select them, then right-

Take the table and put it in the hotbar along the bottom of the inventory. Close the inventory, select the table on your hotbar, and click

click on a solid surface to place the block in the world. Use them to build a basic house with a 1x2 hole for an entrance, then make a door using the following recipe:

Place the door over the entrance and right-click to open and close it. Now you have a place to call home. If you decide to go mining, you’ll come across many different ore as you explore. We’ll cover what you do with these in the next issue, but if you find any coal, combine them with a stick like this:

This will create a wooden axe. Put this on the hotbar and use it when gathering wood. Axes shorten the time it takes to break wooden blocks. Gather more wood, then make these four tools: This will make a torch. Not only will this make things easier to see, but it will also prevent monsters spawning in the immediate area, as they dwell in dark places. Keep caves and the area around your home well-lit! If you ever forget any of these, you can see all the recipes you’ve unlocked by clicking the book icon in your inventory, or to the left of the crafting table interface when you open it. Or, click the recipes in the interface to automatically craft that item. If you ever die, your character will drop all of its items before respawning. Remember where you are in relation to the world, so you can get your stuff back. Next issue, we’ll look at more advanced tools and materials that can really enhance your Minecraft adventure. b

15

Minecraft

BY SIMON BATT


e h t n o s n o e g Pi FIVE

8: page is zle on like th e puz MEET r to th L WE nswe SHAL The a HEN pell W You s

Puzzles

BY TIM SLAVIN

T EET A ETS M says L ssage ’s me friend Your

16

Math puzzles help us learn to solve many kinds of problems. The ability to reduce complexity to the simplest possible units is key to learning CS and programming. This problem comes from one of the oldest collections of mathematical problems, Problems to Sharpen the Young. Some scholars say the author might have been Alcuin, who lived from about 732 to 804 AD. Alcuin lived near the city of York, England, and became head of the Cathedral School at York which today exists as St. Peter’s School. Here is the problem to solve. (My teenage son also tells me this is an unfair puzzle to unleash on third graders. Perhaps.) A staircase has 100 steps. On the first step stands a pigeon; on the second, two pigeons; on the third, three; on the fourth, four; on the fifth, five; and so on, on every step up to the hundredth where there are 100 pigeons on the hundredth step. How many pigeons are there altogether? If 100 steps is too hard, find the answer for 20 stairs, or 10 stairs. Here are answers to the puzzle. Let’s begin by solving this problem for 10 stairs, to see what insights we might get to help solve the problem for 20 or 100 stairs. It’s also easier to use a chalkboard or

piece of paper to map out all the possibilities for a simpler version of this puzzle. Here’s one way to solve for 10 stairs: 1+2+3+4+5+6+7+8+9+10

That’s difficult. And it doesn’t scale for 100 stairs or 20 stairs. So let’s think a different way. What if, instead of counting individual stairs, we counted in pairs? That would reduce our counting in half. And what if you tried different pairs of stairs, for example, counting the 1 pigeon on stair 1 with the 9 pigeons on stair 9? That’s 10 pigeons, an easy number to remember. If you look deeper, you’ll notice this pattern: 1+9 (stair 1 has 1 pigeon + stair 9 has 9 pigeons) 2+8 3+7 4+6 Of our 10 stairs full of pigeons, four pairs each add up to 10, don’t they? If you add the pigeons on stair 5 and stair 10, your count looks like this: 1+9 (stair 1 has 1 pigeon + stair 9 has 9 pigeons) 2+8 3+7 4+6 5 10 That can be expressed this way: (4 x 10) + 5 + 10

That’s much easier to calculate than adding each number individually, isn’t it? It’s 55 pigeons total on the 10 stairs. Also notice the number of pairs is the total number possible (for 10 stairs, 5 possible pairs) minus 1 pair ( the middle stair that pairs with the top stair), or in this case 4 possible pairs that equal 10. Let’s apply this pair solution to 20 stairs: 1+19 (stair 1 has 1 pigeon + stair 19 has 19 pigeons) 2+18 3+17 4+16 5+15 6+14 7+13 8+12 9+11 10 20

The nine pairs each total 20 with the pigeons on stairs 10 and 20 counted as singles. The calculation: (9 x 20) + 10 + 20 That’s also much easier to calculate than adding up all numbers from 1 to 20. For 20 stairs, we have 180 pigeons in pairs of stairs plus 30, or 210 total pigeons. Also notice the number of pairs is the total number possible (for 20 stairs, 10 possible pairs) minus 1 pair (the middle stair that pairs with the top stair), or in this case 9 possible pairs that equal 10. So let’s tackle 100 stairs. The total number of pigeons on the first stair and 99th stair is


s r i a t S 100 (1 pigeon on the first stair + 99 pigeons on the 99th stair). Same for the total number of pigeons on the second stair and the 98th stair. And the third stair and the 97th stair. Every pair of stairs equals 100 pigeons, except the middle stair (50th) and top stair (100th). This partial list gives an idea of how you can count in pairs to calculate the number of pigeons quickly:

17

TK

Here is a deceptively simple math puzzle that’s at least 1200 years old.

1+99 = 100 pigeons 2+98 3+97 4+96 5+95 6+94 7+93 8+92 9+91 10+90 ... 20+80 ... 25+75 ... 30+70 ... 40+60 ... 49+51 50 pigeons on the 50th step 100 pigeons on the 100th step Thus you have 49 pairs of 100 pigeons for 4900 pigeons, plus 50 pigeons from the 50th step and a final 100 pigeons from the 100th step, for a total of 4900 + 50 + 100 or 5050 pigeons. Also notice the number of pairs is the total number possible (for 100 stairs, 49 possible pairs) minus 1 pair (the middle stair that pairs with the top stair), or in this case 49 possible pairs that equal 100. b

I’m not a pigeon, so don’t count me! For more puzzles, check out the link on the back cover of this issue.

JOHN BASTOEN, FLICKR TOP LEFT, JANS CANON, FLICKR


Circuits

18

For info on Micro:bit go to https://microbit.org/resellers

BY LES POUNDER

Thirsty Plants Lve Micro:bit! Continuing our look at the micro:bit, let’s create a plant protector that will measure the moisture of the soil and alert us when it drops below a certain level. We’ll use a sensor to monitor the conductivity of the soil. Wet soil is a good conductor of electricity and means our plant has enough water. Dry soil is a poor conductor, and our plant protector invention will alert us to this.

Remember that water and electricity don’t mix. NEVER submerge your micro:bit, sensor of battery pack in water as this will lead to damage. Do not water the plant while the plant protector is in the soil.

Project: The Plant Protector You need:

• Any computer with an Internet connection • A micro:bit • A speaker with 3.5mm headphone jack • 5x Crocodile clips

• 3x Female to Male Jumper Wires (Du Pont connectors) • A Soil Moisture Sensor • A USB power bank or micro:bit AAA battery pack. • A plant

lie over the coding area, to the right of the screen. Blocks can be moved from the menu to the coding area and connected in the same manner as with Scratch. At left there’s an interactive micro:bit simulator so we can test our code.

Building the Circuit

The Soil Moisture Sensor can be found online or via sellers like Adafruit. The sensor receives 3V and GND from the micro:bit, powering the sensor. Power is passed from one tip, through soil, to a receiving tip, which sends voltage as an output to our micro:bit. It’s read on Pin 1 and converted to a value of 0 to 1023. 0 means the plant has no water and 1023 means the plant is saturated. The circuit diagram and photo below show how the wires are connected.

The headphones require two croc clips. The black one connects to the base of the headphone jack, and then connects to GND on the micro:bit. The white one connects to the tip of the headphone jack and then to Pin0 of our micro:bit.

Basic menu expanded, showing the blocks.

PXT Project

Getting Started PXT

Go to https://pxt.microbit.org. Start with a blank project.

The micro:bit pxt blocks interface looks and feels like the Scratch editor.

PXT 101

The pxt editor is block based, so click on the block menu, left center of the screen. To open a menu, click on it and you will see blocks. This expanded window will briefly

Clear the “on start” block from the coding area, drag it to the menu and drop it. We’ll write the code inside the “forever” loop. First, create a Variable. Go to Variables and click on “Make a Variable”. Call it “soil”. Then, drag the block “set soil to 0” and place it inside the loop. If you don’t see this block, it might be called “set item to 0”. If so, use that block and click on the dropdown arrow to change the variable to “soil”. Next, you’ll store some data


inside the “soil” variable. In this project the variable is used to store the conductivity of our soil, which is a value from 0 to 1023, representing the voltage conducted via the soil. The sensor is connected to Pin 1 of the micro:bit. To access the pin click on “Advanced”, then find the “Pins” menu. Drag the “analog read pin P0” and place it over the zero of “set soil to 0”. Now change the pin to P1. This means that the value being read by the sensor will be stored in our variable, “soil”.

In order to check the value given by the sensor against what we consider to be “fairly dry” and “very dry” we need to use a conditional test called “if”. Go to the “Logic” menu and drag the “if true, then” block and place it inside the “Forever loop” and underneath our previous code. Now you can see a blue “cog” in the top left of this block. Click on it and you will see “if”, “else if” and “else” blocks. Assemble them so that we have, from top to bottom, “if”, “else if” and “else”. To close the pop up click on the cog.

We now need to use an “ __ and __” block from “Logic”, drag and place this over the “true” of our

conditional test. In the first blank space of “__ and __” we shall go back to “Logic” and drag a “0 < 0” block and place it in the blank. This block tests to see if the value in the first blank is less than the value in the second blank. Our first value will be the data stored in our “soil” variable, so go ahead and get that block and place it in the first blank. In the second blank we need to set a limit, in this case we typed the value “500” as this is roughly half the value of conductivity, meaning our soil may be a little dry. Grab another “0 < 0” block and place it in the other blank space of our “and” block. Again, the first value is our “soil” variable, but change the < to a > symbol to check that the soil moisture, and its conductivity, is between 200 and 500 for this condition to be evaluated as True. In the last blank space type “200” to set the lower limit.

If the soil moisture reports to be between 200 and 500 then the “if” condition is “True” and the code inside the condition is activated. To show that the plant is unhappy, use the “show icon” block from “Basic” and set it to “sad” Then, go to the “Music” menu and drag “play tone Middle C for 1 beat” so that it connects under the previous block. This will play a slow “heartbeat” indicating the plant requires water.

For the “else if” condition, again

19

use the “0 < 0” block from the “Logic” menu, but this time only compare the value inside the “soil” variable with < 200. This means that the plant is in dire need of water. If this condition is True, then we use another “show icon” block from “Basic” and set it to “angry”. Then, use a “play tone Middle C for 1 beat” block from “Music” but change the tempo to “½ beat” to quicken the heartbeat.

For the final “else” condition we do not need to set any values to compare against. “Else” is used in case all of the previous conditions are False. If all are False, then Else MUST be True. In this case we use it to show that the plant is healthy and well watered. Use the “show icon” block from “Basic” , and give the plant a happy face. We now have all of the code for this project. Click on Download, then connect your micro:bit to your computer. Copy the file from your Downloads folder to the micro:bit. It will reboot and then run the code. Disconnect the micro:bit from your computer and power it using a USB power bank or the official micro:bit AAA battery pack. Place the sensor into the soil and listen to your plant! b

 

 


b safe online

20

a d r e o t a w e s r s C a P e r u c Se

BY PATRICIA FOSTER

We want passwords that are easy to remember, but hard to crack. What makes a password good? To understand this, let’s look at common hacking attacks. BRUTE FORCE ATTACK

If you’re trying to rob a house, an elegant solution is to pick the lock. A brute force solution is to break down the door. For guessing passwords, the brute force solution is to try every single combination. Computers are getting faster, so passwords that were safe five years ago can now be brute forced in a few days. Defeat this by using long passwords; it takes longer to try every single combination. Also, use compound words, like ‘pineapple’. String words together, for example, ‘afternoon_pineapple_sundae’. It’s 26 characters long and easy to remember! What about 23_afternoon_pineapple_ sundae? Even better! DICTIONARY ATTACK

‘Pineapple’ is easier to remember than ‘usbjwlfdi’ because ‘pineapple’ is a real word. Using ‘dictionary attacks,’ hackers only make guesses using real words from the dictionary. However, afternoon_pineapple_sundae is still a decent password. Why? Because ‘pineapple’ is an unusual word. ‘Afternoon’, though, is easier to guess. So use weird words, and word combinations that don’t go together. At first, people switched letters with numbers. ‘O’ became ‘0’, ‘E’ became ‘3’, ‘L’ became ‘!’. Hackers figured this out quickly. Now, their dictionary attacks check obvious number-letter substitutions, so try unusual ones. Switch a ’T’ for an 8! A ‘G’ for a 2! You can also transform a real word into a non-word by placing a random symbol in the middle. For example, pineapple could become pin&eapple, or pineapp$le. SOCIAL ENGINEERING

If you use social media, what kinds of things do you post? Perhaps you show off photos of friends or pets. All this information is now available for anyone on the internet to see—including hackers. So if your pet’s name is part of your password, that information isn’t secret anymore. Even if you don’t use social media, it’s a good idea not to use personal information in your passwords. Never use names or birthdays, change your password at least once a year, and don’t tell anyone your password. OTHER TRICKS

RAINER STROPEK, FLICKR TK

To learn more, check out the link on the back cover of this issue.

1. Use words from different languages in your password. 2. Use motor patterns when creating your password. For example, ‘vfrtyhnbv’ looks random, but it’s actually a box pattern. Start at ‘V’, go upwards on your keyboard to ‘R’, then right to ‘Y’, then down to ’N’, the left back to ‘V’. Easy to remember; hard to guess. 3. Think of a sentence, then take the first letter of every word. For example, ‘I went to school riding on a dinosaur’ is easy to remember but ‘iwtsroad’ is a nonsensical jumble! b


Take a look at the top two images to the right. Can you find any differences between them? From space, the differences seem subtle, but close up they represent major changes to the land that affect the people nearby. In this case, the images were used to detect the construction of illegal gold mines in Tambopata National Reserve, Peru. As a result, the construction was stopped and the local town’s water supply was saved from mercury poisoning. This is one of thousands of problems that Planet Labs sets out to identify with its “miniature” satellites. How? Planet Labs is able to take a picture of nearly every place on earth, nearly every day. Their satellites follow a suncincronus orbit, traveling one after the other in a line circling the planet. If the earth were stationary the satellites would only be able to capture the same strip of land and sea every day. However, the earth rotates below this line of satellites, so while the cameras follow the same orbit, the ground below them changes! Since Planet’s satellites are small and relatively cheap to manufacture, they are able to build and launch them quickly. In fact they have the largest fleet of satellites in the world, currently 150 in total! With so many satellites, Planet Labs is able to detect changes all over the world. The bottom two images to the right are of the Amazon Rain Forest, taken approximately two weeks apart: Once we identify changes to the environment, we can send experts to investigate, work to prevent further damage, and educate people in better methods. Designing, manufacturing, and building the satellites requires teams of people with different backgrounds. The technical aspects of the work include optical, electrical, and software engineering. In addition to the technical aspects of building satellites, Planet Labs believes that artists bring a unique perspective to both the design and aesthetics of satellites. Each satellite includes artwork on the body and wings, giving Planet Labs claim to the largest art collection in space! Computer science also plays a key role. Satellites use code to communicate with the engineers back on earth. Code is the language behind change detection in the images. Because wifi does not exist at that altitude, the computer scientists use code to develop their own wifi-like system that transfers signals between earth and the satellites. Interested in seeing more? Go to https://www.planet.com/, or navigate to Planet Labs’ blog at https://medium.com/planet-stories. You’ll see our world in a whole new light! b Look closely!

21

Show and Tell

s b a L t e n a Pl BY JENNIFER NEWELL


Gift Guide 2017

22

Gift beanz STEAM Guide 2017

https://beanz.com//steam-tools This resource lists all kinds of STEAM tools for kids, organized by grade level.

LAURA LAROSE, FLICKR


23

STEAM Books

The Big Book of Maker Space Projects Written by two school librarians who love handson, low-cost, classroom-tested projects for all ages. Wishlists on their book site make it easy to find what you need. Recyclable hacks, musical instruments, paper and sewing circuits, and tons more. https://colleengraves.org/ bigmakerbook/

Lauren Ipsum

Lift-the-Flap Computers and Coding Over 100 flaps to learn how computers and programming works. Great for all ages (because most people don’t know much about computers). http://bit.ly/2ceT6o9

No Starch Press re-issued Lauren Ipsum, which explains CS concepts in a fun and often wacky way similar to Alice in Wonderland. Re-read the text to realize you’ve learned a key concept in CS and computing! https:// nostarch.com/laurenipsum

Secret Coders Four graphic novels weave coding into adventure stories and puzzles about students who solve mysteries at their school. Written and illustrated by a high school computer science teacher. http://secret-coders.com/

So You Want to Be a Coder? This book is about the other part of software programming: What skills do programmers use and need to know? What do they do all day? http://bit. ly/1ZxErnz

Robots Sphero

While they have evolved their robots to celebrate Star Wars this fall, all their robots are fun, easy to use, and offer a path for kids who want to do more. You’ll need a phone or tablet to connect to your Sphero and direct it. Sphero software also includes OVAL, a C-like language to learn to write code. http://sphero.com

Codea-pillar

Dash and Dot These cute, round robots from the Wonder Workshop are for elementary school age kids. The Dash and Dot robots can be programmed with Blockly, a fairly easy language to master. With Blockly you create a step. A combination of steps determines how the robot will move, when it will move, and what it will do. http://bit.ly/2cYpAWi

LEGO Mindstorms Take the LEGO concept, add icon-based programming, wheels, legs, and other mobile pieces, and you have LEGO Mindstorms. You can build simple or more complicated robots to perform tasks. They respond to touch and are controlled by a remote control. Mindstorms also includes an active online community with lots of ideas to try. http://mindstorms.lego.com

Cubetto This robot requires no computer screen, only play. Program the Cubetto robot with touch, pressing down block shapes in order to tell the robot what to do. You don’t need to know English, or any language, to make the robot move. It’s a clever idea geared towards younger kids.

Code-a-pillar This Fisher-Price learning toy is in the shape of a caterpillar. Kids experiment as they develop problem solving, planning, and critical thinking skills. Change its segments to make the caterpillar go different places. http://bit.ly/2cAbAjf

Ozobot Two small robots, Evo and Bit, provide a deceptive amount of learning opportunities, creativity, and fun. http://ozobot.com/

Cubetto


24

Apps

Electronics Kits

Kids learn to code by making games on the Bitsbox.com website, and then play them on their phone or tablet. The games are quite clever with fun, bright graphics. And it’s easy for kids to adapt the code once they figure out the game, while learning and becoming comfortable with code. A new box of games arrives each month Ages 5 and up. http://bitsbox.com

Today’s electronic kits often don’t require soldering and other semirisky skills. Kids and adults can snap together kits, then tinker with hardware and software. It’s great hands on fun, as well as a way to learn more in depth how computers work. Kits range in complexity from snap together to basic boards with lots of online tutorials. They make fun holiday gifts for older kids who have patience and persistence.

Bitsbox

Codea

Bitsbox

If you are selfsufficient, don’t mind looking up help, and like to take things apart, Codea is for you! An iPad app to create games, you can adapt existing code or create from scratch. There are few limits on what you can create. Ages 10+. http:// twolivesleft.com/ Codea/

Hopscotch This iPhone and iPad app uses blocks you drag and drop to create effects. It has a strong community of kids who often come up with creative ways to have fun. Ages 5+ http://gethopscotch.com

Tynker Many US kids are familiar with Tynker from their classrooms. Tynker is a block language, meaning you drag and drop blocks and configure them. It’s easy and fun to move blocks around, find sprite images, and make the blocks do things. Ages 5+ https://www.tynker.com/

Move the Turtle Little kids can move a “turtle” around the screen by setting direction and the number of steps in order to create artwork and solve problems. The game teaches basic coding ideas and prepares kids for block languages like Scratch, Hopscotch, and Tynker. http://movetheturtle.com

Piper Follow real engineering blueprints to build your own computer then use Pipercraft, a Minecraft mod, to configure it. You also can build gadgets with electronic boards. Steve Wozniak, co-founder of Apple, apparently loves Piper. Includes wood case. https://playpiper.com/

Kano This is a very simple snap together computer kit. The brains are powered by a Raspberry Pi and Kano includes an excellent operating system designed for kids. Also includes an online community to share ideas. https://kano.me

Jewelbots An unusual but really neat idea for kids who want to create friendship bracelets with functionality they can code. http://jewelbots.com/

Swiftie, Touch Lua, Python 3.4 For kids ready to code, there are apps that let them learn how to code with Swift (Swiftie), Lua (Touch Lua), and Python (Python for iOS). SoloLearn has a number of apps and languages. Find them in the App Store and Google Play. Another great option? Find Python projects in books or online, then try them out with the Repl.it website.

Run Marco! A coding adventure game in English and 26 other languages. Kids use conditional logic and critical thinking skills to help Marco get through his adventures. https://allcancode.com/runmarco

The Foos This iPhone and iPad app helps kids ages 5-10+ work through levels where they can play and learn basic programming and computer science skills. https://thefoos.com/

Jewelbots Tech Will Save Us Educational tech toys that are kits kids can build to mix building, craft, science, tech, coding, and fun. Their Mover Kit is like a DIY Jewelbots. https://techwillsaveus.com


25

Little Robot Friends

Redfern They sell their Crumble board with robot kits with motors, LEDs, and sensors.All programmable with a Scratch-like drag and drop language. https://redfernelectronics.co.uk/

Little Robot Friends These cute little robots respond to light, touch, voice, and infrared inputs. They also blink, beep, and buzz. Plus coding! http://littlerobotfriends.com/

Piper

littleBits Easy snap-together electronic pieces make a large number of different kits, and make it fun to invent things. http://littlebits.cc/

TinkerCrate A monthly STEM project arrives in the mail with materials, blueprints, and many ideas for learning and fun activities. http://www.kiwicrate.com/tinker

Kano


26

Board Games Some of the best ways to learn about programming are through board and card games. You don’t need electricity or a computer, and they’re fun for little kids, bigger kids, and families. And don’t forget chess, Go, backgammon, and other traditional games which are fun and teach problem solving and strategy skills.

Robot Turtles Robot Turtles is a great board game with an online community where you can create your own game boards. These games sometimes let you replace the object you direct with a favorite person, adding another level of fun and engagement. http:// thinkfun.com/robotturtles/

Code Monkey Island Programming, mysteries, and fun for kids ages 8 and older. If played as a family, it’s likely younger kids will understand the game too. Use cards to move a monkey around the island as kids learn strategic thinking, logic, and how to adapt. http:// codemonkeyplanet.com/

Code Master This single player game, from the makers of Robot Turtles, has 60 levels you work through to learn programming logic. Only one path leads to the crystal and wins

Code Monkey Island the game. http://thinkfun.com/ codemaster

Bits and Bytes This card game teaches basic computing skills: logic, problem solving, and critical thinking. The game is absorbing and flexible. No need for a computer. http://bitsandbytes.cards/

littlecodr This deceptively simple card game for kids 4-8 lets them lay out a series of steps for others to follow. When they master the basic game, they can add more advanced cards. http:// littlecodr.com/

as well as posters for both cards. It’s also possible to download the poster and cards to print locally if you can’t pay $10 USD for cards or $25 USD for the posters. http://notabletechnicalwomen.org/

Giggle Chips A set of creative game cards created by a mom and her young, doodling daughter that teach computer science concepts in a fun, visual way. http://gigglechips.bigcartel.com/

Notable Women in Computing Card Deck A traditional 52-card deck featuring women who have contributed to technology. It can be used to play Fish and any classic card game. The makers also offer cards with women from the Middle East and Africa,

CodingFarmer Players make their way to a farmhouse, navigating tractors past obstacles, recharging at windmills, and relaxing at rest stops. Game can be played with instructions in English or Java code. http://bit.ly/2cMghWd

CodingIsGood Two-player card game for kids 10 years and up. Basic, Intermediate, and Advanced cards let kids challenge each other in their knowledge of Python, an accessible programming language. http://bit. ly/1YhWVKo

Bits and Bytes


27

Virtual Reality Virtual reality kits vary only in quality of the experience—the ability to trick your eyes and ears into believing the digital world around you is real. For headsets connected to computers, virtual reality also requires the latest video cards and processors to stream data to the headset without interruption.

MAURICIO PESCE, FLICKR

Where to begin if you want to try VR out? Google Cardboard is the least expensive place to start. All you need is their viewer and a phone to create a headset. More expensive headsets connect to smartphones, Playstation, computers, and other platforms. Vive, for example, has a headset that uses base stations to fix your position once connected to your computer. If you choose one of the high end virtual reality kits, be aware of exclusive software, DRM (digital rights management), and other things that will limit your ability to try out software. For example, software built solely for one virtual reality platform means other platforms can’t use it. And open platforms can use software from anywhere as long as it conforms to basic standards.

Google Cardboard For $20-$30 USD you can buy a cardboard headset then slide in a modern smartphone and use VR apps. While not as immersive as the HTC Vive, the experience is as amazing as more expensive options. https://vr.google.com/cardboard/

HTC Vive

Vive While this is the most elaborate VR setup, the use of base stations to fix your position places you accurately in a VR world. At the least, definitely find a Microsoft store with an HTC Vive setup and try it out. It’s amazing. Oculus Rift is worth a look, but may offer content that only works on a Rift. https://www.vive.com https://www.microsoft.com/en-us/store/locations/htcvive/

Playstation VR The Playstation platform has added virtual reality to its games. You need a Playstation 4, but if yours is an older model, or you don’t have one and want to buy, the VR version of the platform could be lots of fun. https://www.playstation.com/en-us/explore/playstation-vr/ b

Google Cardboard

LARS PLOUGHMANN, FLICKR


Parents and Teachers

28

BY JEREMY JOVEN

Overcoming Common Challenges in the CS Classroom Although Computer Science and programming share commonalities with the other core subjects, it proves to be a challenging field for most students, including parents and teachers. Here are some common challenges teachers encounter on a daily basis with tips for overcoming them. Tackling Fixed Mindsets— Highlight Mistakes, Not Just Successes

Programming is a unique skill that requires a particular mindset when being learned and applied. In programming, “bugs” or errors in code are expected. All major software companies recognize this inevitability and, as a result, hire quality assurance engineers to troubleshoot and debug code. Apple, for instance, routinely finds bugs in its iOS software, hence the reason why many iPhone users are prompted to update the software on their devices every few months. In the computer science classroom, teachers will often valorize student successes and forget to equally highlight their mistakes. This assists in creating a classroom culture in which mistakes are instantly correlated with failure and frustration, instead of being seen as tools for highlighting holes in students’ thinking. Learned helplessness is common in the computer science classroom when students face repetitive and consistent errors in their code and have no tools for fixing these errors. Because mistakes and the associated frustration are inevitable when programming, teachers

should nurture students’ mindsets around expecting errors and equip them with strategies for identifying their mistakes and tools for debugging them. Teachers can help students develop a debugging mindset by first teaching them about the common types of bugs in programs and how to identify them. When working with text-based programming languages, there are two major types of bugs: syntax and logic errors. Syntax errors are bugs that hinder a program from compiling and running (missing a semicolon after a command, improper capitalization, etc.). Logic errors produce an undesired output or outcome. By identifying the type of error in their code first, students can then systematically choose an appropriate debugging strategy to fix their program. The question tree below can be used to help students identify the type of error in their code.

Breaking Down Adverse Stereotypes—Emphasize Collaboration Through Projects With Social Application

Programmers and software developers are frequently stigmatized as nerds, as socially awkward, and as predominantly male. Much of this stigmatization stems from the unfortunate portrayal of programmers in the media, often as men coding in siloes; think about Sheldon Cooper from The Big Bang Theory. However, much of the work that software developers do opposes this traditional stereotype as their work requires strong collaboration between team members and across departments. Many teachers unintentionally perpetuate these stereotypes in the classroom by structuring their lessons in a way that underutilizes authentic and collaborative discussions and group work. In many computer science classrooms, you will find students working independently on their computers with little to no opportunities to discuss their code or work with others in developing code. This reinforces reclusive behaviors that potentially deter female student interest in computer science, as research often references socialization as a factor in female interest in STEM studies. MIT App Inventor is a webbased program that allows users to create simple apps for Android devices. The platform uses blockbased programming, similar to that of Scratch. To promote discourse and collaboration in the computer


TK

science classroom, teachers can encourage students to complete coding projects in MIT App Inventor that attempt to solve a social issue. For instance, students may do research and realize that students at their school are having difficulty studying for a particular class. Using App Inventor, the students can create an app that helps users test their knowledge of that particular subject. Investing Parents or Guardians— Encourage Parents/Guardians To Be Learners

If you think students struggle with programming, try teaching their parents or guardians how to code. Programming is a relatively new subject area in elementary and middle schools and many parents believe they possess little to no capacity in helping their children with computer science. A lack of comfortability with the subject matter, coupled with a lack of access to appropriate resources, renders many parents helpless in supporting their children with coding. As computer science continues to grow, it is important that teachers provide spaces for dialogue that support parent investment in computer science and provide parents strategies for supporting their children at home. One way parents or guardians can support their child is through cultivating their child’s curiosity and confidence with coding. Teachers should provide parents with online learning resources (i.e. Codecademy, Code.org, Khan Academy, BrainPOP, etc.) where they can learn to code alongside their children. While coding together, parents also could model how they push through short-term failures and debug their code to their children. This helps reinforce grit-based mindsets that students could further develop in the classroom. b

29


“On the internet, nobody knows you are a dog.” —Peter Steiner The New Yorker Thank you for reading this issue of beanz ! Check out the links below to read stories from this issue online with links to learn more. Makes Sense to Me! http://beanzmag.com/ lego-ev3-sensors

Camel Case http://beanzmag.com/ camel-case

Create a Secure Password http://beanzmag.com/ create-secure-passwords

Tidbitz http://beanzmag.com/ tidbitz-october-2017

Piet: A Language of Colors http://beanzmag.com/ piet-language

Planet Labs http://beanzmag.com/ planet-labs

The Uncanny Valley http://beanzmag.com/ uncanny-valley

Charred Cats http://beanzmag.com/ scratch-charred-cats

STEAM Gift Guide 2017 http://beanzmag.com/ steam-gift-guide-2017

Pigpen Ciphers http://beanzmag.com/ pigpen-ciphers

The Tool Box http://beanzmag.com/ minecraft-tool-box

An Electrifying Idea! http://beanzmag.com/ electricifying-thread-project

Pigeons on the Stairs http://beanzmag.com/pigeonson-the-stairs

Overcoming Common Challenges in the CS Classroom http://beanzmag.com/ teaching-cs-ideas

Cat and Mouse http://beanzmag.com/ cat-mouse-code-project

Thirsty Plants Love micro:bit! http://beanzmag.com/microbitthirsty-plants


Turn static files into dynamic content formats.

Create a flipbook
Issuu converts static files into: digital portfolios, online yearbooks, online catalogs, digital photo albums and more. Sign up and create your flipbook.