var dataTypes = [
"string",
1,
1.0,
true,
[1, 2, 3],
{
name: "yeuimu",
age:22,
getName: function() {
return this.name;
},
getAge: function() {
return this.age;
}
},
function() {
return 1;
},
null,
undefined
];
const printDataType = (value) => {
console.log(`Data Type: ${typeof value}`);
}
dataTypes.forEach(printDataType);
console.log(dataTypes[5].getName());