Khan Academy
More While Loops: Balloon Hopper
Starting with an empty computer screen for a coder can be as intimidating as a bare canvas to a painter or a blank sheet of paper to a writer. Where do you start? If you know what you are trying to build, then you just pick something and...
Khan Academy
Object Types
Young coders learn how to use a function to create objects with similar properties and to allow for the creation of objects repeatedly with a short video that makes the point that coding with a function eliminates repetitions.
Khan Academy
Object Methods, Intro to JS: Drawing & Animation, Computer Programming
This video shows young programmers how to use the same concept to duplicate objects with different properties and attach functions to them. This method allows functions to be easily called with various objects.
Khan Academy
Intro to Drawing
Leap right into programming in JavaScript with this first video in the series. Start off with drawing a rectangle. Remember computers only know what you tell them. So you need to specify exactly where on the screen you want the...
Khan Academy
Arrays of Objects, Intro to JS: Drawing & Animation, Computer Programming
Expand your beginning coder's use of objects in programs by looking at examples where you can change code to define and use objects in arrays and pass objects as parameters to a function. All of this leads to a deeper understanding of...
Khan Academy
Modifying Arrays, Computer Programming
An instructional video combines arrays, loops, and mouse clicks. The author shows how to modify JavaScript code to add a balloon each time the mouse is clicked. The video also shows two different ways to add to the end of the array: one...
Khan Academy
Looping Through Arrays, Computer Programming
In computer programming, loops and arrays are made for each other. This video describes adding a while loop to print out each element in an array and then doing the same procedure using a for loop.
Khan Academy
Modifying Objects, Computer Programming
Similar to using variables, object properties can be changed in the program. However, you can also dynamically add new properties while the program runs. The video shows how to define an object, use an object property, change an object...
Khan Academy
Intro to Objects, Computer Programming
When you introduce objects and object-oriented programming to your coding students, you are starting them on an important path. This introductory video shows how to replace the use of many variables with the use of a single object...
Khan Academy
Intro to Arrays, Computer Programming
Explore more cool programming features by learning how to use arrays in JavaScript code to tackle lists or sequences through a single variable. This video introduces arrays and specifically shows how they are defined and used.
Khan Academy
For Loops! A New Kind of Loop, Computer Programming
Now that you are familiar with while loops let's look at a new type of loop: the for loop. This video shows the three parts of the for loop: the start, the Boolean test, the value change, and how it differs from a while loop.
Khan Academy
Nested For Loops, Computer Programming
A loop within a loop is called a nested loop. It expands the repeating code based on two different variables. The video shows an example of drawing an image across and down a screen.
Khan Academy
Intro to While Loops, Computer Programming
Repetitive tasks, like the scenes from the movie Ground Hog Day, are common in computer programs. But how exactly do you program a piece of code to repeat specific instructions? This is where the While loop comes in handy. This video...
Khan Academy
If/Else - Part 2, Computer Programming
This is the second part of the introductory video on the if statement. It looks specifically at the else if clause in JavaScript code. Two examples are shown: one where the options are mutually exclusive and could have been programmed...
Khan Academy
If/Else - Part 1, Computer Programming
Do it, or else! In conversation, this sounds like an ultimatum, but when writing code, it's a normal way to communicate with a computer. This video shows how to extend our previously used conditional if statement to include the else...
Khan Academy
Booleans, Computer Programming
As one accumulates more life experiences, there are fewer and fewer things that are strictly one thing or another. There always seems to be some gray area or middle ground. Not so with Boolean data types! We are in a world of only two...
Khan Academy
Logical Operators, Computer Programming
As the author in this video states, "Life is complex." To handle this complexity, programming languages use something called Boolean operators. In a simple JavaScript code example, this video shows how to set up a conditional statement...
Khan Academy
Function Return Values, Computer Programming
Functions that do calculations usually need to return a value. In this video, a function calculates and returns the total number of donuts eaten based on the years someone has been alive. Hopefully, your charges will have eaten much less...
Khan Academy
Function Parameters, Computer Programming
Learn how functions in coding are even more helpful when you can pass parameters to them. The author shows how to modify a simple JavaScript function to have two parameters that help you position a repeated drawing to the correct place...
Khan Academy
Functions, Computer Programming
The next step in your class's development as young programmers is learning to define and use a simple function in JavaScript code. Younger students may require some additional explanations to help highlight the importance of functions....
Khan Academy
More Mouse Interaction, Computer Programming
Creating interactive programs can be very exciting for new computer programmers. The author shows how to use mouseIsPressed within a conditional statement to create a small JavaScript program that responds to the user's mouse press.
Khan Academy
Incrementing shortcuts, Computer Programming
Text messages full of abbreviations can be easier to understand once you know what the letters stand for. The same goes for reading code because computer programmers always devise ways to reduce typing. One typical line of code that...
Khan Academy
More Drawing!
Now let's expand our coding to include ellipses, rectangles, and lines using this easy-to-follow video. We are also adding some formality to the language we use by defining the following terms: function, parameters, pixels, and the x and...
Khan Academy
Intro to Coloring
Programming without color is like watching the Wizard of Oz in black and white, you understand what's going on, but you lose the visual impact of the story. Here, we learn to add color to the images we are coding. Background,...