Your Web News in One Place

Help Webnuz

Referal links:

Sign up for GreenGeeks web hosting
January 13, 2021 01:41 pm GMT

Getting started with JavaScript : The Definitive Guide

I started reading out this book a week ago and here I'm trying to break-up a few things I understood while getting started.

Chapter 1 : Introduction to JavaScript.

JavaScript is a high-level, dynamic, interpreted programming language that is well suited to Object oriented and functional programming styles with multi-paradigm. It has curly-bracket syntax, prototype-based object-orientation, and first-class functions. It is basically everywhere around us.
I know what you're thinking. Alright, I accept these are a lot of jargons to take in abruptly. So let's get our feet into the deep waters one foot at a time.

Alt Text

What is High-level Programming language?
In computer science it can be explained as a programming language that uses abstraction(providing relevant information in a type). Means we all know machine cannot understand natural languages that humans speak. They only understand the binary or machine level language, which consists of only zeroes and ones. Now what earlier software engineers did for us was they kind of made a dictionary in which they wrote down sequences of 0's and 1's so that when we type something in our natural language the machine will have a reference to look up to, to understand what it exactly means in machine level language.

Alt Text

A dynamic programming language is nothing but just a class of high level programming language in which operations otherwise done at compile-time can be done at run-time. In JavaScript it is possible to change the type of a variable or add new properties or methods to an object while the program is running. This is the ability of a dynamic language.
Interpreters run through a program line by line and execute each command so if a command in JavaScript is executed, that is done in the manner previously mentioned and thus becomes an interpreted language. The point to note here is that in compiled languages that are directly converted into machine code, they tend to be faster than interpreted languages. But with the development of JUST-IN-TIME compilation the gap is shrinking.

Alt Text

Chapter 2 : Lexical Structure.

When learning any new language one needs to keep in mind that every language in this world has a particular script and a particular set of defined rules on which the whole language relies upon. Like you know how American English has the same letters as British English but still both are different in ways. Pronunciation, spelling of particular words etc. Similarly in every programming language there is a set of elementary rules that specifies how you write programs in a particular language. This is called lexical structure or in simple words its syntax. Important points to remember are that :

  1. JavaScript is a case-sensitive language.
  2. JavaScript ignores excess whitespace along with line breaks except for those that are a part of string or regular expression literals.
  3. Currently according to ECMAScript 6 there are total of 48 reserved keywords in JavaScript.
  4. JavaScript programs are written using the Unicode character set.
  5. Semicolons are optional.
  6. Primitive types (inbuilt or predefined datatypes and methods linked to them).

We will continue to discuss the further chapters.
If you think this article can be improved do let me know.


Original Link: https://dev.to/rohinibali/javascript-the-definitive-guide-1l5i

Share this article:    Share on Facebook
View Full Article

Dev To

An online community for sharing and discovering great ideas, having debates, and making friends

More About this Source Visit Dev To