Week 3 Day 2: JavaScript ES6 features

This commit is contained in:
2026-01-09 15:50:45 +05:30
parent 6d6a8fd0ea
commit 865fcf0db7
3 changed files with 54 additions and 0 deletions

9
Week-3/Day-2/script.js Normal file
View File

@@ -0,0 +1,9 @@
const user = {
name: "Harshit",
role: "Intern"
};
const greet = ({ name, role }) =>
`Hello ${name}, Role: ${role}`;
console.log(greet(user));