Introducing binary numbers: part I.I
In my first post about binary numbers, I mentioned that I wanted to teach my kids how 0′s and 1′s could be used to represent colors. Instead of talking about it too much, I just built a little web page so they could explore it on their own.
It is pretty bare-bones, but seems to get the point across pretty well. My kids have already given me a long list of requested improvements: sliders, preset colors, mixing arbitrary colors, and more. Please let me know if you have any suggestions!
This little web page did lead to some interesting discussions. It let us start talking about how a computer would store a picture, one block of color at a time. Then we noticed that if we just changed one “unimportant” 0 to a 1 or 1 to a 0, we couldn’t notice the change in colors. This means that we an send secret messages in pictures:
- Take a picture
- Write your message in binary (using a code like the one we made up in my last post)
- Change every fourth bit in the picture to match the next bit in your message
- Now you have a picture that looks just like the original, but contains a secret message.
Gunnar really liked this idea. Of course we didn’t talk about file formats or any of that stuff yet, so he doesn’t really understand how to do it. But we’ll get there. And we’ll send secret messages.