-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathTugas 6.js
More file actions
40 lines (37 loc) · 830 Bytes
/
Copy pathTugas 6.js
File metadata and controls
40 lines (37 loc) · 830 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
//1
/*
Array merupakan struktur data yang digunakan untuk menyimpan berbagai data dalam satu tempat. Sedangkan onjek adalah sebuah variabel yang menyimpan nilai dan fungsi.
*/
//2
var hobi = ['Main Game', 'Coding', 'Travelling']
console.log(hobi)
//3
var saya = {
nama: 'Muh. Resky Fadil',
umur: 19,
alamat: 'Jalan Anoa, Kabupaten Bone',
hobi: hobi
}
console.log(saya)
//4
const sekolah = [
{
namaSekolah: 'SD Negeri 8 Watampone',
jurusan: undefined,
tahunMasuk: 2008,
tahunKeluar: 2014,
},
{
namaSekolah: 'MTsN 1 Bone',
jurusan: undefined,
tahunMasuk: 2014,
tahunKeluar: 2017,
},
{
namaSekolah: 'SMAN 13 Bone',
jurusan: 'MIPA',
tahunMasuk: 2017,
tahunKeluar: 2020,
}
]
console.log(sekolah)