GoConqr has a new look! Let us know what you think.

Flowchart

Numbers data type overview

Kostas Diakogiannis Web Developing Junior Certificate English

Flowchart content

  1. JavaScript Numbers Type

  2. Numbers Data Type

    Essentially numbers data type gives us the opportunity to work with numbers and perform mathematical operations and calculations with them.

    For example: let a = 10; ​​​ // This is how you create a number

    The commonest mathematical operations are also supported in JavaScript with the use of arithmetical operators.

    10 + 15 // returns 25, + is the JS addition operator

    15 - 10 // returns 5, since - is the JS subtraction operator

    10 * 10 // returns 100, since * is the multiplication operator

    10 / 10 // returns 1, since / is the division operator

    10 % 3 // returns 1, since this is the remainder of the division (10 / 3). The remainder and not the result!! This is called the modulo operator.

    10 ** 2 // returns 100, this is the square of 10

    100 ** (1 / 2) // returns 10, the square root of 100. See Math module for more operations like that.

    parseInt('10') // converts the '10' from type string to type number 10.

    parseFloat('6.5') // converts the '6.5' decimal from type string to type number 6.5 ​​​

    You can find out whole String documentation here!

Information

Description
Junior Certificate Web Developing (JavaScript) Flowchart on Numbers data type overview, created by Kostas Diakogiannis on 12/10/2018.
Views
3
History
  • Created by Kostas Diakogiannis · Oct 12, 2018
  • Copied by Kostas Diakogiannis · Oct 12, 2018
Rating

Feedback

What is it about?

What do you think of the new look?

How do you like it?