1. Introduction to Create a Joke-Telling Talkbot
attachment

Playback Speed:
Transcript

You may have used specific instructions to give someone directions, for example.

If you said, “Go down the hall, turn left, and then it’s on your right,” you gave that person code in the form of directions to the cafeteria.

Computers use similar code – they just need you to be much more specific.

The browser you’re using to watch this video right now was made with code written by software engineers and programmers.

They design computer programs and write the code to run it.

But anyone can use code to customize programs and make something completely new.

You may have a smart speaker in your home or a virtual assistant on your phone; these are both examples of talkbots.

You ask a question or make a request – like what’s the weather today? or set my alarm for 6:30 a.m. – and then the talkbot responds with predefined answers, finds the answer online, or directs you to other resources.

The talkbot you will create in this lesson will tell a knock knock joke.

But you can write any joke you’d like.

To write the code for your talkbot, you’ll use a script editor.

The script editor you’ll use for this lesson is called Apps Script.

It’s the same editor used for many Google products, like Google Docs and Google Sheets.

You’ll use Apps Script to write a type of code called JavaScript, which many websites and web applications use.

To work on this lesson, you will use your Google account.

Open a new tab in your browser, and navigate to google.com If you are not signed in, do so now.

If you don’t have a Google account, pause the video and create one.

Then, click the link next to this video to open the starter project in Apps Script.

Scroll through the code in the file.

Don’t worry if you don’t understand the code.

You don’t have to know what all of the code means to edit it.

Even professional software engineers don’t know everything.

In the side panel in Apps Script, open the Overview tab.

Make a copy of the starter project.

Rename your project anything you’d like, but include your name.

Instructions

  1. Sign in to your Google account.
  2. Open the starter project linked next to this video.
  3. Make a copy of the project.
  4. Name your project.