forked from bethrobson/Head-First-JavaScript-Programming
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathfun.html
More file actions
41 lines (28 loc) · 427 Bytes
/
fun.html
File metadata and controls
41 lines (28 loc) · 427 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
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Fun</title>
<script>
function fun(echo) {
console.log(echo);
};
fun("hello");
function boo(aFunction) {
aFunction("boo");
}
boo(fun);
console.log(fun);
fun(boo);
var moreFun = fun;
moreFun("hello again");
function echoMaker() {
return fun;
}
var bigFun = echoMaker();
bigFun("Is there an echo?");
</script>
</head>
<body>
</body>
</html>