-
Notifications
You must be signed in to change notification settings - Fork 0
/
javascript 48.js
38 lines (29 loc) · 954 Bytes
/
javascript 48.js
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
function nice(name) {
console.log("hey " + name + " you are nice")
console.log("hey " + name + " you are good!")
console.log("hey " + name + " you are nice")
console.log("hey " + name + " your tshirt is nice!")
console.log("hey " + name + " your course is good too!")
}
// console.log("hey harry you are nice")
// console.log("hey harry you are good")
// console.log("hey harry your tshirt is nice!")
// console.log("hey harry your course is good too!")
// nice("Rohan")
// nice("shivam")
function sum(a, b, c = 3) {
// console.log(a + b)
return a + b + c
}
result1 = sum(8, 9)
result2 = sum(4, 4)
result3 = sum(6, 3, 1)
console.log("the sum of these numbers is:", result1)
console.log("the sum of these numbers is:", result2)
console.log("the sum of these numbers is:", result3)
const func1 = (x)=>{
console.log("i am a arrow function", x)
}
func1(34);
func1(66);
func1(84);