This learning module is intended to be an introduction to computer science suitable for K-12 students, along the same lines as the Girls Who Code program, or a summer “College for Kids” course, though it would be equally applicable to beginning undergraduate students in their first computer science course. It provides an overview of what computer science is and what computer scientists do, an introduction to four key concepts of CS (loops, variables, conditionals, and functions), and suggestions for next steps students can take to continue their journey learning CS.
computer science, cs, programming, Scratch, loops, variables, conditionals, functions
This learning module is intended to be an introduction to computer science suitable for K-12 students, along the same lines as the Girls Who Code program, or a summer “College for Kids” course, though it would be equally appropriate for beginning undergraduate students as part of their first computer science course (which would likely continue to introduce another programming language like Java or Python, as well as additional concepts). It provides an overview of what computer science is and what computer scientists do, an introduction to four key concepts of CS (loops, variables, conditionals, and functions), and suggestions for next steps students can take to continue their journey learning CS.
This learning module contains eight updates on the following topics:
It also includes a project with an assessment rubric.
Before you continue reading this week's update, please fill out the survey attached to this post, which asks you a few questions about what you think computer science is.
Now, watch the following video from Code.org:
As the video shows, computer science is more than just coding. It is also the study of problem solving, and computational thinking can be applied in a variety of different fields.
Comment: What are your thoughts on the video? Did it change or reinforce the way you think about computer science?
As researchers like Fidoten and Spacco report, many people have a fundamental misunderstanding of what computer scientists really do; since students using this learning module likely have very little experience with computer science, it is important to begin with an introduction to the field so that they know both what to expect from this course and what opportunities there are for computer scientists to use their skills.
The video and survey in this update are drawn from Girls Who Code's lesson plan 0.1, available here. The full facilitator's guide is also available online here, and contains self-guided projects, example activities, and a great deal of advice on how to help students learn. Code.org also has a variety of instructional materials that may be useful, such as their Tips for Introducing CS.
A pre- and post-survey are included to measure how students' attitudes toward CS change over the course of the module. The questions are:
Computers can do a lot of things, but only if someone tells them what to do. That's where programming (or writing code) comes in: a computer program is a set of instructions for a computer to follow. Coding can be a fun and creative process, and can accomplish a lot of things.
However, as this video mentions, these instructions for the computer have to be written very clearly, or the computer will get confused and probably won't do what you wanted it to. Consider the following video:
In the video, the dad is following his childrens' instructions very literally, just like a computer would, and as you can see, the children sometimes get frustrated as they work on their instructions. This often happens to programmers as well! However, it is important to remember that coding, like everything else, takes practice and will become easier as you get more familiar with it.
Comment: Pick an activity (like the sandwich-making in the video), and practice writing precise instructions for it that you think a computer would be able to follow. Then read other students' instructions and think about whether they would work!
Computer science is about more than just programming, but it is a major part of the field, and so students must become accustomed to it. Learning to write instructions in a way that computers can understand can be difficult, so students may be overwhelmed at first. It is helpful to start with an activity like this to get students used to thinking computationally, before exposing them to an actual programming language.
A fun in-class activity that can help give students another look at what a program is is the Intelligent Piece of Paper by Peter McOwan and Paul Curzon.
Both here and later in the module, it is important to promote a growth mindset as opposed to a fixed mindset (see, for example, this article for advice on how to do this). Students-- especially girls-- may feel that they "aren't smart enough" to program, and care should be taken to make it clear that this is not true.
In the last update, you started thinking about how to give instructions to a computer so that it will do what you want. However, computers aren't able to understand human languages like English. Instead, we use programming languages.
For this update, you will begin using Scratch, a block-based programming language.
Watch the following video for a brief look at why block-based languages are great for beginners:
For this week, make an account on the Scratch website and start working through the "Getting Started" tutorial. Over the next few weeks, you will be learning some basic computer science concepts and learning how to use them in Scratch.
Comment: Look at some of the example Scratch projects on this page. If you want, you can use the "Explore" tab in Scratch to find even more projects. Which are your favorites, and why? How do they inspire you to make your own project?
As the video in this update mentions, block-based programming languages like Scratch and Google's Blockly are becoming more and more popular to teach beginning students how to program, since they remove most of the difficulties caused by the more intimidating syntax of text-based programming languages like Java and C. Block-based languages are the subject of much current research (e.g., Zaidi, Freihofer, & Townsend; see this search for more) as we work to better understand their benefits and drawbacks.
Scratch has a help page with additional tutorial videos here, and a tips section here that includes inspiration for student projects. In addition, Girls Who Code has an excellent self-guided Fashion in Scratch project that covers all four of the CS concepts used in this module.
Students should begin the Scratch project with this update, and continue working on it for the rest of the module.
The first core programming concept in this module is loops. Loops allow you to repeat instructions without having to right them multiple times:
The following webpage explains how to use loops in Scratch: Scratch for Budding Computer Scientists: Loops
Try adding a loop to your Scratch project from last time!
Comment #1: Other than what was mentioned in the video, when might you use a loop in real life? In a program?
Comment #2: Are you having any problems or difficulties with your Scratch project so far? Post a comment describing them, and try to offer someone else help with their problem.
This update and the three that follow present four common CS concepts: loops, variables, conditionals, and functions. These are the "Core4" concepts taught by the Girls Who Code program (see the Facilitator's guide linked in Update 1), and are standard inclusions in introductory CS courses at all levels. They are among the simplest concepts in CS, and are present in almost all programs, so it is important that students master them early.
For some tips from other educators on teaching loops, see the discussion here.
The next concept is variables. Variables are placeholders for values, so that you can refer to that value without knowing exactly what it is, just like we might use x or y as a variable in math.
Watch the following videos for an introduction to variables (keep in mind that in the video, they are not using Scratch, so some of the details of writing code using variables will be different from what you will do in this module):
Now read the following webpage for a description of using variables in Scratch, and try using some in your project: Variables Tutorial
Comment #1: When might you use a variable in real life? In a program?
Comment #2: Are you having any problems or difficulties with your Scratch project so far? Post a comment describing them, and try to offer someone else help with their problem.
Students may be familiar with the concept of variables from math; however, there are some subtle differences with how they are used (especially "=" meaning assignment). The Box Activity is one example of an in-class activity that may help clarify these issues.
See also some teaching tips here: Analogies and Approaches
Conditionals help computers make decisions. They involve Boolean expressions, which are statements that are either true or false. See the following page for a description of Boolean expressions in Scratch: Scratch for Budding Computer Scientists: Boolean Expressions
The most common conditional is the if statement. Watch the following short video from Code.org to hear Bill Gates give a simple example of how these statements work:
Now, check out this article on how to use conditionals in Scratch and try adding some to your project: Scratch for Budding Computer Scientists: Conditions
Comment #1: Other than the examples in the video, when might you use a conditional in real life? In a program?
Comment #2: Are you having any problems or difficulties with your Scratch project so far? Post a comment describing them, and try to offer someone else help with their problem.
As with the other CS concepts so far, there are many online resources with lesson plans and other tips to help teach contidionals. See, for example, Computer Science Education Week and Flocabulary, which has an excellent Choose-Your-Own-Adventure style activity.
The last CS concept in this module is functions. Functions are pieces of code that can be given a name and reused without rewriting any code. Watch the following videos for an introduction to functions (again, the second video is not using Scratch, so you can ignore the details of how to write functions):
Now, read this article about using functions in Scratch and try to add one to your project: Custom Blocks
Comment #1: Other than the examples in the videos, when might you use a function in real life? In a program?
Comment #2: Do you have any last problems or difficulties with your Scratch project? Post a comment describing them, and try to offer someone else help with their problem.
As with variables, students may be familiar with functions from math. They can, however, still be confusing, especially if they are a new concept. Here is an example in-class activity that can help explain what functions are and how to use them: Functional Suncatchers
Now that you are familiar with Scratch and the four basic CS concepts introduced in the module, what's next? You could:
Remember, computer science is very exciting field that interacts with a huge number of other areas, and getting involved can take you almost anywhere you want to go. Check out this video of musician Imogen Heap and how she applies CS to her music:
Comment: Research someone who uses computer science or technology in a creative or interesting way, and share a brief description of their work. How do they inspire you to use commputer science?
Now that the module is complete, please also take a moment to fill out the attached survey about what you think of CS.
This update contains suggestions for next steps for students. The first two (text-based languages and data structures) follow immediately from the content of this module, since they are common topics in undergraduate-level introductory courses. The latter suggestions (investigating subareas and researching inspiring figures) are more abstract and return more to the early themes of this module, in an attempt to encourage students to stick with CS. The choice of Imogen Heap as an example figure was drawn from Girls Who Code's first lesson plan; selecting a woman was deliberate, as being exposed to female role models in the industry can be very helpful for female students, who are traditionally underrepresented in CS and other STEM fields (see for example Zaidi, Freihofer, & Townsend; much research has been devoted to this topic).
Teachers may also wish to tell students about the optimistic job outlook for careers related to CS; see this article for an overview: Computer Science Job Prospects for the Graduating Class of 2016
For this assignment, you will create a project of your choice in Scratch. This can be a game, animation, story, or whatever you like! You are allowed to remix other Scratchers' work, but if you do, you must credit them in your description. You should also make significant changes from the original project.
Your project should include:
Please paste a link to your project in this Work.