-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy patharrayIterationJS.html
More file actions
34 lines (32 loc) · 1.39 KB
/
arrayIterationJS.html
File metadata and controls
34 lines (32 loc) · 1.39 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Array Iteration JS</title>
</head>
<body>
<h1>Array Iteration JS</h1>
<h2>testing</h2>
<h3 id="test">Test zone for iteration</h3>
<h2>Test forEach Iteration</h2>
<button onclick="forEachTest()">forEach</button>
<h2>Map iteration creates new value by running a function on each element of array</h2>
<button onclick="mapTest()">map</button>
<h2>Filter iteration returns new array if it passes test</h2>
<button onclick="filterTest()">filter</button>
<h2>Reduce returns all the array elements into one value***Initial total is first Index or Set second paramenter</h2>
<button onclick="reduceTest()">reduce</button>
<h2>Reduceright starts from right to left </h2>
<h2>Every runs all and returns a boolean if all pass function </h2>
<h2>Some checks if any pass function test and returns boolean</h2>
<h2>Indexof returns index of array with such value </h2>
<h2>lastIndex returns last occurence of value</h2>
<h2>find returns first occurence of array that passes function test</h2>
<h2>findindex returns index of first element that passes function</h2>
<h2>Arrayfrom craetes an array from an object that has length or iterable</h2>
<h2>Keys creates a key of iterator of array</h2>
<h2>Entries returns key value pairs of array</h2>
<h2>includes returns true if array has a value of </h2>
<script src="js/arrayIterationJS.js"></script>
</body>
</html>