SHOW STAFF VIEW  
LEVEL 1
135  MEMBERS DID THIS ACTIVITY

Text Compression

Learn how to store text files using less space.

Start your session with a community builder. For community builders suggestions, download the YDToolbox App

To build a sense of belonging, check in with members by asking a question like "What songs do you know that have lots of repetition?”

Tell your members that they might be trying something brand new today, and remind them that asking questions is important. Revisit any expectations or norms around group discussion or using technology or devices in your Club.

WHAT YOU'LL NEED

Computer
WiFiInternet
Headphones
Speakers
 

STEP 1
TIME: 5 MINUTES

Txt Me

In areas where text space might be limited, there are way to reduce the length of some messages. For example, Twitter has a cap of 140 characters and many text messages are limited to 160 characters. What are some ways that messages can be shortened to include more information in less space? Some words might be abbreviated, like ‘lol’ in place of saying ‘laughing out loud’, or spelled using numbers that sound similar.

Compression is a method that computers use to store more information in less space. Like saving characters space in texts, there are a lot of ways this can be done. With text compression, repeated sections are marked and only stored once, so that space isn’t wasted on the same data.

Think about messages that you’ve sent recently. Can you think of something you’ve done to make one of them shorter?
This step can be done as a group discussion or slightly altered to integrate discussion on messaging and phone use in general.

STEP 2
TIME: 10 MINUTES

Repeated Text

Think about the chorus of a popular song. These are probably phrases and lines that are repeated fairly often through the whole song. If a computer needed to share those lyrics, it could compress the common parts so that it doesn't have to send the same information over and over.

Check out this video featuring Aloe Blacc from Code.org.

It uses lyrics from Aloe Blacc’s “Wake Me Up” to show how commonly used words can be compressed.

If you need to show the “Digital Compression with Aloe Blacc” video without an internet connection, you can download it from code.org.

You can show this video on a projector to a large group at once. Ask members to think about their favorite songs and what common parts could be compressed in the same way.

STEP 3
TIME: 15 MINUTES

Try It Out

Try it yourself. There are lot of ways to practice text compression. Try it online with Code.org here.

Text compression goes the other way too. Try this decompression activity. See if you can get compressed words back into full form in this box of text

This activity can be done offline in the same way, with printouts instead of webpages. See the CS Unplugged Text Compression activity here

STEP 4
TIME: WILL VARY

Make Your Own

Now’s your chance. Come up with your own song lyrics, poem or message to compress. Trade with a friend to see who can do the most compressed text and then put it back into full form. Upload your project for a star.
If members need some help creating videos or recording, direct them to the Media Making activities for those topics.

 Module Completed?

Notify your staff that you've completed this activity!

Ready to share your project?

Upload your favorite project to be featured!

UPLOAD

Amazing Computer Science Projects
)

Newsfeed

FILTER

VIEWING: FILTER



No Results Found...