You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: Week1/MAKEME.md
+9-9Lines changed: 9 additions & 9 deletions
Original file line number
Diff line number
Diff line change
@@ -66,13 +66,13 @@ Ciao, mondo! // Italian
66
66
Hola, mundo! // Spanish
67
67
```
68
68
69
-
\.2. Consider the following code:
69
+
2\. Consider the following code:
70
70
```
71
71
console.log('I'm awesome');
72
72
```
73
73
2\.1 Copy the code in your `.js` file and run it. You will see that you will get a SyntaxError. Find a solution for this error, Hint read the error message carefully, it also gives an indication of where the problem is.
74
74
75
-
\.3. Declare a variable `x` and initialize it with an integer.
75
+
3\. Declare a variable `x` and initialize it with an integer.
76
76
3\.1 First, _declare_ your variable `x`.
77
77
3\.2 Add a console.log statement that explains that explains in words what _you think_ the value of `x` is, like in this example:
78
78
```js
@@ -94,7 +94,7 @@ console.log('I'm awesome');
94
94
// TODO -> log value of x again
95
95
```
96
96
97
-
\.4. Declare a variable `y` and assign a string to it.
97
+
4\. Declare a variable `y` and assign a string to it.
98
98
4\.1 Write a console.log statement in which you explain in words what _you think_ the value of the string is
99
99
4\.2 Now console.log the variable `y`.
100
100
4\.3 Now assign a new string to the variable `y`
@@ -109,15 +109,15 @@ console.log('I'm awesome');
109
109
// TODO -> log the actual value of the string to the console
110
110
```
111
111
112
-
\.5. How do you round the number 7.25, to the nearest integer?
112
+
5\. How do you round the number 7.25, to the nearest integer?
113
113
5\.1 Declare a variable `z` and assign the number 7.25 to it.
114
114
5\.2 Console.log `z`.
115
115
5\.3 Declare another variable `a` that has the value of z but rounded to the nearest integer.
116
116
5\.4 Console.log `a`
117
117
5\.5 So now we have `z` and `a` find a way to compare the two values and store the highest of the two in a new variable.
118
118
5\.6 Console.log the highest value.
119
119
120
-
\.6. Arrays!
120
+
6\. Arrays!
121
121
6\.1 Declare an empty array (you can decide on how to call it yourself, but read on a bit here and see if you can find a good name that exactly describes what this variable will hold).
122
122
6\.2 Write a console.log statement that explains in words what you think the value of the array is.
123
123
6\.3 Console.log your array.
@@ -126,13 +126,13 @@ console.log('I'm awesome');
126
126
6\.6 Add a statement that adds Daan's favorite animal (baby pig) to the *existing array*
127
127
6\.7 Log your new array!
128
128
129
-
\.7. More strings
129
+
7\. More strings
130
130
7\.1 Let's consider the following string: `let myString = "this,is,a,test"`.
131
131
7\.2 Add the string to your file and console.log it.
132
132
7\.3 Find a way to get the length of `myString`.
133
133
7\.4 Console.log the length of `myString`.
134
134
135
-
\.8. Write a program that checks the types of two variables and prints out `SAME TYPE` if they are the same type.
135
+
8\. Write a program that checks the types of two variables and prints out `SAME TYPE` if they are the same type.
136
136
8\.1 First declare at least four variables and assign them different data types.
137
137
8\.2 For each variable write a `console.log` statement that logs the value
138
138
```js
@@ -156,10 +156,10 @@ if () {
156
156
// TODO -> add a way of giving feedback if your variables don't have the same type
157
157
```
158
158
159
-
\.9. If `x` equals 7, and the only other statement is `x = x % 3`, what would be the new value of `x`?
159
+
9\. If `x` equals 7, and the only other statement is `x = x % 3`, what would be the new value of `x`?
160
160
9\.1 Add at least 3 `console.log` statements in which you show that you understand what `%` does.
161
161
162
-
\.10. Write a program to answer the following questions:
162
+
10\. Write a program to answer the following questions:
163
163
10\.1 Can you store multiple types in an array? Numbers and strings? Make an example that illustrates your answer.
164
164
10\.2 Can you compare infinities? (Not in Eyad's world) - does 6/0 === 10/0? How can you test this?
165
165
10\.3 Add console.log statements to the above program's in which you show that you understand the concepts (just like you've done in the above assignments).
0 commit comments