Lesson Planet
Search educational resources
  • Sign In Try It Free
  • AI Teacher Tools
    • Discover Resources Search reviewed educational resources by keyword, subject, grade, type, and more
    • Curriculum Manager (My Content) Manage saved and uploaded resources and folders To Access the Curriculum Manager Sign In or Join Now
    • Browse Resource Directory Browse educational resources by subject and topic
    • Curriculum Calendar Explore curriculum resources by date
    • Lesson Planning Articles Timely and inspiring teaching ideas that you can apply in your classroom
    • Our Story
    • Frequently Asked Questions
    • Testimonials
    • Contact Us
  • Pricing
  • School Access
    • Your school or district can sign up for Lesson Planet — with no cost to teachers
      Learn More
  • Sign In
  • Try It Free

Hi, what do you want to do?

Create a lesson plan
Create a lesson plan
Generate resources with 80+ AI teacher tools
Generate resources with 80+ AI teacher tools
Search 200,000 instructional videos
Search 200,000 instructional videos
Find a teaching resource
Find a teaching resource
Challenge: Double Rainbow InteractiveChallenge: Double Rainbow Interactive
Publisher
Khan Academy
Resource Details
Curator Rating
Educator Rating
Not yet Rated
Grade
6th - Higher Ed
Subjects
STEM
1 more...
Resource Types
Activities & Projects
1 more...
Audiences
For Teacher Use
1 more...
Duration
30 mins
Instructional Strategies
Guided Practice
2 more...
Usage Permissions
Creative Commons
BY-NC-SA: 3.0
cc
Interactive

Challenge: Double Rainbow

Curated and Reviewed by Lesson Planet
This Challenge: Double Rainbow interactive also includes:
  • JavaScript Guide
  • Student Reference
  • Join to access all included materials

Draw a rainbow over the rainbow. The second segment in a series of six has the class practice using functions to edit a program that draws a rainbow. After creating the function, the interactive lesson challenges pupils to create another rainbow using the same function.

8 Views 8 Downloads

Concepts

javascript, computer code, Computer Programming, coding, computer drawing, animation, computer science

Additional Tags

object oriented programming, drawing and animation coding, programming in javascript

Instructional Ideas

  • After going through the tutorial, have pupils develop code to create three rainbows of different size and location
  • Ask class members to explain what each element in the drawRainbow function does

Classroom Considerations

  • Individuals should be familiar with using functions to define objects

Pros

  • Provides hints while participants are creating the code
  • The resource includes projects that employ the learned skill

Cons

  • None

See similar resources:

App

Lightbot Jr 4 Coding Puzzles

Sprite Box
Learning how to write computer code has never been so much fun! Given control of their very own robots, children create simple programs in order to solve a series of challenges and develop their problem solving skills.
2nd - 8th STEM
Instructional Video

Function Parameters, Computer Programming

Khan Academy
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...
5 mins 6th - Higher Ed STEM
Instructional Video

A Tour of Programming on Khan Academy

Khan Academy
Explore, create, and make mistakes. This is the call to action in a video on how to use Khan Academy to learn to write Java code. The speaker encourages learners to feel comfortable with the programming environment that is provided on...
6 mins 5th - Higher Ed STEM
Instructional Video

More Mouse Interaction, Computer Programming

Khan Academy
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.
4 mins 6th - Higher Ed STEM
Instructional Video

Object Methods, Intro to JS: Drawing & Animation, Computer Programming

Khan Academy
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.
5 mins 6th - Higher Ed STEM
Activity

Connect the Dots: Isometric Drawing and Coded Plans

Teach Engineering
Individuals discover how to draw cubes on triangle-dot paper. They use cubes to build structures and draw corresponding isometric drawings on dot paper in the second lesson of the series of five. The activity also introduces the concept...
6th - 12th Math
CCSS: Designed
Instructional Video

Intro to Drawing

Khan Academy
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...
6 mins 5th - Higher Ed STEM
Instructional Video

More Drawing!

Khan Academy
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...
5 mins 5th - Higher Ed STEM
Lesson Plan

Creating Functions

Code.org
Quit repeating yourself ... you can make this simpler! Rather than repeating the same set of code over and over, class members learn to build and call functions in a series of challenges in App Lab. In the end, they combine...
9th - 12th STEM
Interactive

Project: Build-a-House

Khan Academy
Start with a basic house created in JavaScript code and practice programming with loops as you add rows of windows, grass, flowers, or trees. How about some apples growing in the trees? You get the idea. Your coding students can let...
6th - Higher Ed STEM
Try It Free
© 1999-2026 Learning Explorer, Inc.
Teacher Lesson Plans, Worksheets and Resources

Sign up for the Lesson Planet Monthly Newsletter

Open Educational Resources (OER)

  • Health
  • Language Arts
  • Languages
  • Math
  • Physical Education
  • Science
  • Social Studies
  • Special Education
  • Visual and Performing Arts
View All Lesson Plans

Discover Resources

  • Our Review Process
  • How it Works
  • How to Search
  • Create a Collection

Manage Curriculum

  • Edit a Collection
  • Assign to Students
  • Manage My Content
Contact Us Site Map Privacy Policy Terms of Use