Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 9 additions & 1 deletion solutions/01_hello_html/hello.html
Original file line number Diff line number Diff line change
@@ -1 +1,9 @@
This is just an example! Hehe.
<!DOCTYPE html>
<html>
<head>
<title> </title>
</head>
<body>
Hello World
</body>
</html>
5 changes: 5 additions & 0 deletions solutions/02_headBody/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
<!DOCTYPE html>
<html>
<head>Hello!</head>
<body>World!</body>
</html>
8 changes: 8 additions & 0 deletions solutions/04_hello3ages/hello3ages.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
var age1 = prompt("How old are you?");
var name1 = prompt("What is your name?");
var age2 = prompt("How old are you?");
var name2 = prompt("What is your name?");
var age3 = prompt("How old are you?");
var name3 = prompt("What is your name?");

alert(name1 + "-" + age1 + "\n" + name2 + "-" + age2 + "\n" + name3 + "-" + age3);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice use of the newline character! Can you think of a way we can do this without writing prompt more than twice? (hint: loops)

11 changes: 11 additions & 0 deletions solutions/04_hello3ages/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<!DOCTYPE html>
<html>
<head>
<title> </title>

<script src="hello3ages.js"></script>
</head>
<body>

</body>
</html>
11 changes: 11 additions & 0 deletions solutions/09a_length/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<!DOCTYPE html>
<html>
<head>
<title> </title>

<script src="length.js"></script>
</head>
<body>

</body>
</html>
2 changes: 2 additions & 0 deletions solutions/09a_length/length.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
var myString = "This is just a string";
console.log(myString.length);
11 changes: 11 additions & 0 deletions solutions/09b_nose/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<!DOCTYPE html>
<html>
<head>
<title> </title>

<script src="nose.js"></script>
</head>
<body>

</body>
</html>
3 changes: 3 additions & 0 deletions solutions/09b_nose/nose.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
var noseString = "I like my new shoes";
alert(noseString);
alert(noseString.replace("shoes","nose"));
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

neat!