-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathJs_Array.php
More file actions
53 lines (35 loc) · 769 Bytes
/
Js_Array.php
File metadata and controls
53 lines (35 loc) · 769 Bytes
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
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
<html>
<head>
<title> my javascript </title>
</head>
<body>
<h1> javascript</h1>
<script>
//var text1="shah";
//document.write("<h1>"+text3+"</h1>");
//most use this function in array
//concat
//join
//sort
//reveres
//pop
//shift
//slice
//unshift
var student_name = new Array();
student_name[0]="gold";
student_name[1]="james";
student_name[2]="david";
student_name[3]="jeckin";
var employee_name = new Array();
employee_name [0] ="shah";
employee_name [1] ="faisal";
employee_name [2] ="asad ";
// join mempy +studnt
var total = student_name.concat (employee_name);
for (var i in total) {
document.write(total[i] +"<br>");
}
</script>
</body>
</html>