-
-
Save defields923/e8981f13dee1c782ee96feac158e0472 to your computer and use it in GitHub Desktop.
NumbersNumbers studies// source https://jsbin.com/waseni
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// -----Data Types: NUMBER---- // | |
/* Numbers are simply numeric values used for arithmetic. | |
Whole integers and fractional numbers using decimal points | |
are permitted. With numbers of exceptional size, scientific | |
notation using "e" (exponent) is allowed: */ | |
// 2.998e8 = 2.998 × 10 to the 8th power = 299,800,000 | |
// -----Using Numbers for Arithmetic----- // | |
var sum = 6 + 2; | |
console.log(sum); // logs 8 | |
var subtraction = 6 - 2; | |
console.log(subtraction); // logs 4 | |
var multiplication = 6 * 2; | |
console.log(multiplication); // logs 12 | |
var division = 6 / 2; | |
console.log(division); // logs 3 | |
var fracSum = 6.5 + 2.5; | |
console.log(fracSum); // logs 9 | |
var remainder = 6 % 3; | |
console.log(remainder); // logs 0 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment