Skip to content

Commit 1bc9f0c

Browse files
author
russom
committed
Chrome console alert and prompt functions explained.
1 parent 948d792 commit 1bc9f0c

1 file changed

Lines changed: 7 additions & 1 deletion

File tree

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

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,16 @@ Let's try an example.
99

1010
In the Chrome console,
1111
invoke the function `alert` with an input string of `"Hello world!"`;
12-
1312
What effect does calling the `alert` function have?
1413

14+
- A window pops up with `"Hello world!"` message
15+
1516
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`.
1617

1718
What effect does calling the `prompt` function have?
19+
20+
- a new window popup saying what is your name with a text input field for user to type.
21+
1822
What is the return value of `prompt`?
23+
24+
- A text string that input by the user is returned.

0 commit comments

Comments
 (0)