Created
July 10, 2020 11:01
-
-
Save dimasmiftah/45b28f66569ab3720e5c37c2fe5dd959 to your computer and use it in GitHub Desktop.
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
// CONTOH MUTABLE - OBJECT LITERAL | |
let pemain1 = {nama: 'hinata', umur: 15} | |
let pemain2 = pemain1 | |
pemain2.nama = 'shoyo' | |
console.log(pemain1) // akan menampilkan {nama: "shoyo", umur: 15} | |
console.log(pemain2) // akan menampilkan {nama: "shoyo", umur: 15} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment