JavaScript Basics (Part 2)

Continuing on with yesterdays JavaScript learnings, and continuing to make notes for myself so that I can later refer to them:

JavaScript uses camel-case and it is recommended that camel-case is used for variable names. e.g. firstName, surName, emailAddress.

Like Python, JavaScript can concatenate words and letters whilst dealing with strings.

Like Python, JavaScript can use mathematical operators such as;

/ Division

* Multiplication

+ Addition

– Subtraction

JavaScript refers to a webpage as a document, and can be used to edit the content of the document so it is not static. JavaScript can be used to get the elements of a website i.e. by their element ID, such as document.ElementById() and then update the individual element.

Leave a Reply

Please log in using one of these methods to post your comment: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.