While replacing names of variables. I accidentally deleted the comma after c. But in the real script with real names, it is there.
However, should it be a semi-colon or comma instead of a colon?
I don't get it. If you're asking about error, I'm 100% certain it says this (copy-paste): index.js:7 Uncaught SyntaxError: Unexpected token :.
Now that you mentioned, it turns out I got wrong tutorial from the internet. The array should be
Vars can be separated by commas. The array you mention in the real script is not really an array but an object. Js doesn.t have associated arrays. When commas etc are left out of var lists, the error can often appear downstream as that.s the first "illegal token" that is encountered.