Skip to content
Open
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
12 changes: 8 additions & 4 deletions js-worksheet.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,12 @@
####Topic: JavaScript

* Explain what a function is. Give an example.
* A relationship or a expersion involving one or more variable for example function(){ console.log(name) }
* Explain what a parameter is. Give an example.
* When we want to look up what a word means, we go to a dictionary. Similarly, when we want to look up what a standard JavaScript function does, we look at _______________.
* Paramter is used in subroutine to refer to one of the piece of data provided as a input for subroutine, For example def add(x,y) return (x,y)
* When we want to look up what a word means, we go to a dictionary. Similarly, when we want to look up what a standard JavaScript function does, we look at Google.
* In the following piece of code, what variable(s) are in scope at Point A, Point B, and
Point C?
Point C? It's Point A and B

```
var hooligan = true;
Expand All @@ -23,7 +25,7 @@ function rocks() {

// Point C
```
* What does the following code print?
* What does the following code print? No answer

```
var x = 7;
Expand All @@ -37,9 +39,11 @@ console.log("Outside the function, x is " + x);
someFunction();
```
* Write a function that returns the result of the following equation: 5a^2 + 4b + c. You should use the pow() function. Your function should take in three parameters (a,b,c).
Why you gotta make tis so complaiced it;s way too hard ;-; there's no way.

####Some review
* Close this HTML element (remember HTML??): `<h2> My Books`
* Close this HTML element (remember HTML??): `<h2> My Books </h2>
* What HTML element is used to create an **ordered list** of items?
* ol
* Write a CSS rule that will make only the word *Adams* red:
`<span id="first">Washington </span><span id="second">Adams </span><span id="third>Jefferson</span>"`