In this video, I cover how to define, initialize, and use your own variables for the purpose of animating p5.js sketches. Code: https://thecodingtrain.com/tracks/cod... p5.js Web Editor Sketches: ðđïļ Moving Circle: https://editor.p5js.org/codingtrain/s... ðđïļ Growing Circle: https://editor.p5js.org/codingtrain/s... ðĨ Previous video:    âĒ 2.1: Variables in p5.js (mouseX, mouseY) -...  ðĨ Next video:    âĒ 2.3: Incrementation Operators - p5.js Tuto...  ðĨ All videos:    âĒ Start learning here!  Videos: ð let vs var:    âĒ 16.1: let vs var - Topics of JavaScript/ES6  Timestamps: 0:00 Hello! Let's talk more about variables! 0:18 What are we trying to make? 0:52 What are the steps to making a variable? 1:12 Step 1: Declare 3:01 Step 2: Initialize 4:21 Step 3: Use 5:03 Let's add the code! 5:49 Combining declaration and initialization. 6:43 What is a global variable? 7:31 But the circle isn't moving! How can we fix that? 9:19 How can we make it interactive? 9:50 What's next? Editing by Mathieu Blanchette Animations by Jason Heglund Music from Epidemic Sound ð Website: http://thecodingtrain.com/ ðū Share Your Creation! https://thecodingtrain.com/guides/pas... ðĐ Suggest Topics: https://github.com/CodingTrain/Sugges... ðĄ GitHub: https://github.com/CodingTrain ðŽ Discord:   / discord  ð Membership: http://youtube.com/thecodingtrain/join ð Store: https://standard.tv/codingtrain ðïļ Twitter:   / thecodingtrain  ðļ Instagram:   / the.coding.train  ðĨ Coding Challenges:    âĒ Coding Challenges  ðĨ Intro to Programming:    âĒ Start learning here!  ð p5.js: https://p5js.org ð p5.js Web Editor: https://editor.p5js.org/ ð Processing: https://processing.org ð Code of Conduct: https://github.com/CodingTrain/Code-o... This description was auto-generated. If you see a problem, please open an issue: https://github.com/CodingTrain/thecod... #basics #variables #p5js #javascript