Skip to content

Commit 3d392d4

Browse files
committed
complete chrome.md stretch exercise
1 parent 6ecd7a2 commit 3d392d4

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

‎Sprint-2/4-stretch-explore/chrome.md‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,10 @@ Let's try an example.
88
In the Chrome console, invoke the function `alert` with one argument, the string `"Hello world!"`;
99

1010
What effect does calling the `alert` function have?
11-
11+
answer: calling alert("Hello World!") displays a pop-up dialogue box in the browser window containing the message "Hello World!" and an ok button that poses the script execution until dismissed
1212
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`.
1313

1414
What effect does calling the `prompt` function have?
15+
answer: the prompt exercution returned a pop up dialogue box containing the message and text input field, an ok button and a cancel button.
1516
What is the return value of `prompt`?
17+
answer: it returns the string entered by the user in the text input field when I click ok.

0 commit comments

Comments
 (0)