JavaScript is like Python

To use p5.js you need to know JavaScript.

If you’re learning JavaScript as a second language (after Python), then this brief “JavaScript is like Python” article will demonstrate the JavaScript equivalents of some of the most popular concepts:

https://codeguppy.com/blog/javascript-is-like-python/

3 Likes

I would reccommend learning JavaScript as its own language.
Don’t just learn python equivalents.
JavaScript has WAY more features than Python.

Look at these cool JavaScript features:

var x = (a < b) ? 5 : 99;
var s = 7;
switch(s){
  case 7:
    println("Hello world!");
    break;
  default:
    println("Oh Well...");
}

You will discover similarities once you know both languages.