JavaScript for Kids: A Playful Introduction to Programming

By Nick Morgan

JavaScript is the programming language of the web, the key sauce that makes the net remarkable, your favourite websites interactive, and on-line video games fun!

JavaScript for Kids is a lighthearted advent that teaches programming necessities via sufferer, step by step examples paired with humorous illustrations. you are going to commence with the fundamentals, like operating with strings, arrays, and loops, after which stream directly to extra complicated issues, like construction interactivity with jQuery and drawing photos with Canvas.

Along the best way, you will write video games akin to locate the Buried Treasure, Hangman, and Snake. you are going to additionally find out how to:

  • Create services to prepare and reuse your code
  • Write and alter HTML to create dynamic internet pages
  • Use the DOM and jQuery to make your web content react to consumer input
  • Use the Canvas point to attract and animate graphics
  • Program genuine user-controlled video games with collision detection and rating keeping

With visible examples like bouncing balls, lively bees, and racing automobiles, you could quite see what you are programming. every one bankruptcy builds at the final, and programming demanding situations on the finish of every bankruptcy will stretch your mind and encourage your personal notable courses. Make whatever cool with JavaScript today!

Ages 10+ (and their parents!)

Show description

Preview of JavaScript for Kids: A Playful Introduction to Programming PDF

Similar Children books

Wanted (Pretty Little Liars, Book 8)

Being sought after is not a very good factor. for 3 lengthy years, Hanna, Spencer, Aria, and Emily questioned what occurred the evening their ally Alison disappeared. Now that each one their questions have ultimately been responded, they could positioned this lousy bankruptcy in their lives at the back of them. Or in order that they imagine. no longer each tale has a cheerful finishing, in particular while 4 beautiful little liars have performed such a lot of depraved issues.

Guys Read: Thriller

A physique at the tracksA teenage terroristA mysterious wish-granting machineThe world’s worst inner most detectiveThe moment quantity within the men learn Library of serious examining is brim-full of puzzle, intrigue, and nefarious task. that includes the superior writers round, and compiled by way of qualified man Jon Scieszka, men learn: mystery is a pulse-pounding choice of brand-new brief tales, each absolute to maintain you riveted until eventually the ultimate web page.

Platypus Police Squad: The Frog Who Croaked

Platypus Police Squad: The Frog Who Croaked is the 1st in a sequence of zany, action-packed middle-grade mysteries that includes platypus police detectives Rick Zengo and Corey O’Malley. When a choice is available in a couple of crime down on the docks regarding a lacking schoolteacher and a duffle bag packed with unlawful fish, Zengo and O’Malley are going to need to discover ways to set their modifications apart in the event that they are looking to resolve this.

Secret Water

The Swallows are marooned with a little crusing boat for corporation. Will they live on their probability to develop into actual explorers?      When the Walker family's vacation plans are ruined through Daddy having to paintings, the entire summer season turns out misplaced at sea. yet a lifeless vacation for the kids is simply too depressing to undergo so their mom and dad hatch a plan.

Extra info for JavaScript for Kids: A Playful Introduction to Programming

Show sample text content

One zero five bankruptcy eight: features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 123 half II: complex JavaScript bankruptcy nine: The DOM and jQuery . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 143 bankruptcy 10: Interactive Programming . . . . . . . . . . . . . . . . . . . . . . . . . . . . a hundred and fifty five bankruptcy eleven: locate the Buried Treasure! . . . . . . . . . . . . . . . . . . . . . . . . . . . 167 bankruptcy 12: Object-Oriented Programming . . . . . . . . . . . . . . . . . . . . . . . . 181 half III: Canvas bankruptcy thirteen: The canvas point . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 199 bankruptcy 14: Making issues circulate on the Canvas . . . . . . . . . . . . . . . . . . . 217 bankruptcy 15: Controlling Animations with the Keyboard . . . . . . . . . . . . . . 235 bankruptcy sixteen: creating a Snake video game: half 1 . . . . . . . . . . . . . . . . . . . . . . . . 251 bankruptcy 17: creating a Snake online game: half 2 . . . . . . . . . . . . . . . . . . . . . . . . 267 Afterword: the place to move from the following . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 293 thesaurus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 299 Index . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 305 Contents intimately Acknowledgments xxi Introduction xxiii Who should still learn This publication? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xxiv the best way to learn This publication . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xxiv What’s during this e-book? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xxv celebrate! . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xxvi half I: basics 1 what's JavaScript? three Meet JavaScript . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . four Why study JavaScript? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6 Writing a few JavaScript . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7 The constitution of a JavaScript software . . . . . . . . . . . . . . . . . . . . . . . . . . . . . eight Syntax . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10 reviews . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10 What You discovered . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . eleven 2 info forms and Variables thirteen Numbers and Operators . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15 Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17 Naming Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19 growing New Variables utilizing Math . . . . . . . . . . . . . . . . . . . . . . . . 19 Incrementing and Decrementing . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21 += (plus-equals) and – = (minus-equals) . . . . . . . . . . . . . . . . . . . . . . 22 Strings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 becoming a member of Strings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25 discovering the size of a String . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25 Getting a unmarried personality from a String . . . . . . . . . . . . . . . . . . . . 26 slicing Up Strings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27 altering Strings to All Capital or All Lowercase Letters . . . . . . . 28 Booleans . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30 Logical Operators . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30 evaluating Numbers with Booleans . . . . . . . . . . . . . . . . . . . . . . . . . 33 undefined and null . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37 What You discovered . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 38 three Arrays 39 Why for those who Care approximately Arrays? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . forty developing an Array . . . . . . . . . . . . . . . . . . . . . . . .

Download PDF sample

Rated 4.44 of 5 – based on 14 votes