Skip to content

Commit e844471

Browse files
committed
Update 07_String.js and 08_Math.js.
1 parent d90f8d9 commit e844471

2 files changed

Lines changed: 4 additions & 2 deletions

File tree

07_String.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,8 @@ console.log(typeof new_name); // "object"
2121
console.log(name.length); // "7"
2222

2323
// .concat() - [method] - joins two or more strings
24+
console.log(name.concat(new_name)); // "HitarthNew Hitarth"
25+
// OR
2426
console.log(name + new_name); // "HitarthNew Hitarth"
2527
console.log(name + " " + new_name); // "Hitarth New Hitarth"
2628
console.log("Hello " + name); // "Hello Hitarth"

08_Math.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,10 +51,10 @@ console.log(Math.floor(2)); // "2"
5151
console.log(Math.floor(2.0)); // "2"
5252
console.log(Math.floor(2.1)); // "2"
5353

54-
// .max() - return the maximum vallue in a set of numbers
54+
// .max() - return the maximum value in a set of numbers
5555
console.log(Math.max(1, 2, 3, 4, 5)); // "5"
5656

57-
// .min() - return the minimum vallue in a set of numbers
57+
// .min() - return the minimum value in a set of numbers
5858
console.log(Math.min(1, 2, 3, 4, 5)); // "1"
5959

6060
// .random() - return a random number between 0 (inclusive) and 1 (exclusive)

0 commit comments

Comments
 (0)