Skip to content

Commit 530060a

Browse files
committed
answered the stretch explore of sprint-1
1 parent 19a2fea commit 530060a

2 files changed

Lines changed: 15 additions & 0 deletions

File tree

Sprint-1/4-stretch-explore/chrome.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,15 @@ In the Chrome console,
1111
invoke the function `alert` with an input string of `"Hello world!"`;
1212

1313
What effect does calling the `alert` function have?
14+
it shows a popup message in the browser.
15+
1416

1517
Now try invoking the function `prompt` with a string input of `"What is your name?"` - store the return value of your call to `prompt` in an variable called `myName`.
18+
Shows a popup in the browser asking the user to type something.
19+
The string "What is your name?" appears as the message in the popup.
1620

1721
What effect does calling the `prompt` function have?
22+
Shows a popup dialog in the browser with a message
23+
1824
What is the return value of `prompt`?
25+
If the user types something and clicks OK, returns that string.

Sprint-1/4-stretch-explore/objects.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,12 +5,20 @@ In this activity, we'll explore some additional concepts that you'll encounter i
55
Open the Chrome devtools Console, type in `console.log` and then hit enter
66

77
What output do you get?
8+
A: This tells you log is a function
89

910
Now enter just `console` in the Console, what output do you get back?
11+
A: You get an object with multiple properties and functions
1012

1113
Try also entering `typeof console`
14+
A: Confirms that console is an object in JavaScript
1215

1316
Answer the following questions:
1417

1518
What does `console` store?
19+
A: The object that stores logging/debugging functions
20+
1621
What does the syntax `console.log` or `console.assert` mean? In particular, what does the `.` mean?
22+
Access the log function of the console object.
23+
Dot operator . access this property or method of the object.
24+
Access the assert function of the console object.

0 commit comments

Comments
 (0)