File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -110,7 +110,7 @@ The last important difference I want to talk about is that the `for in` loop wil
110110``` javascript
111111const fruits = [" apple" ," banana" , " orange" ];
112112
113- fruit .eat = " gnam gnam" ;
113+ fruits .eat = " gnam gnam" ;
114114
115115for (const fruit of fruits){
116116 console .log (fruit);
@@ -132,4 +132,4 @@ for (const index in fruits){
132132Since ` for in ` will return the value and not the value itself we nee to access with the syntax ` fruits[index] ` .
133133
134134As you can see, the ` for in ` loop returned the value of the property ` eat ` which we've added after initialization of the variable ` fruits ` .
135- On the other hand, the ` for of ` loop only returned the values that were in the Array when we initialized it.
135+ On the other hand, the ` for of ` loop only returned the values that were in the Array when we initialized it.
You can’t perform that action at this time.
0 commit comments