What to learn next
Have you watched all of the talk-throughs and completed all of the challenges up until this point? Awesome!
- Variables: how to declare variables, assign, re-assign, and local vs. global scope.
- Data types: numbers, booleans, strings, arrays, and objects.
- Functions: how to group code into functions, pass arguments to them, and return values from them.
- Conditionals: how to use if/else statements and logical expressions.
- Loops: how to use while and for loops to repeat code.
- Shapes: like rect(), ellipse(), and line()
- Colors: like fill(), stroke(), and background()
- Text: like text() and textSize()
- Events: like draw() and mousePressed()
- Math: like random() and dist()
Now, there are a ton of ways that you can keep learning programming, both by going deeper into what you've learnt so far or learning something related.
Learn more on Khan Academy
We have three advanced tracks here on Khan Academy, with articles and challenges:
- Advanced JS: Games & Visualizations
- Advanced JS: Natural Simulations (Recommended for those who have some familiarity with basic trigonometry and physics, like in high school).
- Algorithms (Recommended for those who have done logarithms / functions, like in Algebra 2)
Learn more ProcessingJS
ProcessingJS is a powerful library, and we've only introduced half of it.
Besides our advanced tutorials on Games & Visualization and Natural Simulations, you can also watch tutorials created by members of our community:
Work on a big project
Sometimes, the best way to really learn how to program is to work on a project that you're really passionate about.
- Brainstorm ideas for a game, simulation, or story, and pick one that you think would be hard but not too hard.
- Plan it out, using pseudo-code, sketching on paper, or writing it up in a document.
- Start programming it. When you're stuck, try to find programs that do similar things (either from our official talk-throughs or from the community) and ask questions on them.
- Share it with your friends and family when you're done. Reflect on how much you learnt.
Learn web development
Learn new languages
- Python: used for webservers and data processing. Learn it on Codecademy, Treehouse, or with this interactive online textbook.
- Java: used to make Android apps. Learn it on Treehouse.
- Objective C: used to make iPhone apps. Learn it on MakeGamesWIthUs or Treehouse.
- Ruby: used with the Rails framework to create webservers. Learn it on Codecademy or Treehouse.
- PHP: used for webservers. Learn it on Treehouse or Codecademy.
Want to join the conversation?
- Are there going to be any more tutorials? If so, you should probably teach the usage of
- From the author:Sorry, it wasn't meant to be published as a one-liner. I've updated it now with much more!(63 votes)
- Now that I've almost finished this JS Intro course, I'd like to know how to continue outside the Khan Academy environment. How can I access the Processing JS drawing and animation functions and incorporated them into my JS codes using Notepad ++ for example? Thanks, Bob(28 votes)
- To run this on your computer, you need ProcessingJS. You can download Processing.js here: https://raw.githubusercontent.com/processing-js/processing-js/v1.4.8/processing.min.js by saving the file to your computer.
Then, put a
processing.min.jsinto one folder.
Method 1 (Recommended)
Create an HTML file that looks like the example below:
<title>Processing.js inside HTML</title>
<!-- Import Processing.js -->
<!-- Canvas -->
<canvas id = "canvas"></canvas>
<!-- the code -->
<script type="application/processing" data-processing-target="canvas">
// your code here!
// your code here!with your program's code.
Note: this method doesn't work inside Khan Academy.
Follow this template: https://www.khanacademy.org/computer-programming/processingjs-inside-webpages-template/5157014494511104
Just make sure to replace
If you need to visualize this, here is a helpful video that uses a similar method: https://www.youtube.com/watch?v=8gpVTD5xYr4
The Khan Academy Processing.js is a little bit different than the outside world Processing.js. You can find the differences here: https://khanacademy.zendesk.com/hc/en-us/articles/202260404-What-parts-of-ProcessingJS-does-Khan-Academy-support-
For more information on Processing.js, go here: http://processingjs.org/ and http://processingjs.org/articles/jsQuickStart.html
To learn more about HTML, go here: https://www.khanacademy.org/computing/computer-programming/html-css(19 votes)
- Is their a second programming course for JS(15 votes)
- yes there is, there is games and advanced simulations(13 votes)
- So, up above, it says:
If you want to learn more about how this works, go to Reference 2 below. If you want to understand the HTML, go to link 3 to learn it.
P.S. Sorry for being five years late :((17 votes)
Thanks in advance.
Edit: Changed 5+4=9 to 5+4 ==9(4 votes)
- In regards to the first part of your question: Sounds like you already figured out that functions like
fill()are from the processingJS library, which is why you can't use them in codecademy.
For the second part of your question:
first of all to be clear, you can't type
5 + 4 = 9into codecademy and get
true, it must be
Anyways the reason you can do this in codecademy and not khan, is because the first few tutorials are done in the console. Khan doesn't let you write in the console - the window you type code into, is just an editor, so that's why you can't do this.
Just for a little fun, right click this web page, and then click inspect element. Depending on the web browser your using you should see a tab labeled "console". Click it, then inside of this console try typing
5 + 4 == 9and see what happens.
This is the difference between a console, and the editor view in khanacedemy.(13 votes)
- Since there aren't any tutorials on key commands, I'll just ask. How do you use key commands so you can make something on the canvas move using the keyboard? I've always wanted to do that.(8 votes)
- From the author:I've updated the article with links to advanced tutorials that may help with that and other topics.(8 votes)
- Do I have to mention credits in my program if I use codes (or get help) from sites like w3shcools, stackoverflow, etc...?(5 votes)
- Yes, you should mention credits(5 votes)
- You have options :)
Intro to HTML/CSS (used for making web pages):
Intro to SQL (Data management):
Advanced JS-- Games and Visualizations:
Advanced JS-- Natural Simulations:
HTML/JS--Making web pages interactive:
HTML/JS -- Making webpages interactive with jQuery:
- Are you guys going to put up any tutorials about Arduino?(8 votes)
- Harvey Houston is correct, but I'll tell you what you can do on KA; you can use the command:
getSound(, the soundpicker will pop up, and you can choose the sound you want to be played.
However, you can't run it over and over again in a
draw()function, as it is under Disallowed Functionality in the Program Guidelines. Instead, play it when the user interacts with the program, like when a
keyIsPressedor in a