fix broken speech ballon emoji (#18967)
* fix broken speech ballon emoji * Fix speech ballon emoji * Add image warning sign * Update image warning sign link
This commit is contained in:
committed by
Randell Dawson
parent
dd8bb63713
commit
f5ce9f8ddc
@ -19,19 +19,19 @@ You need to check if an element is an array or not.
|
||||
|
||||
##  Hint: 2
|
||||
|
||||
If you are dealing with an array, then you need flatten it by getting the value inside of the array. This means if you have <a href='https://forum.freecodecamp.com/images/emoji/emoji_one/speech_balloon.png?v=3 ":speech_balloon:"' target='_blank' rel='nofollow'>[4]] then instead of returning [4] you need to return 4\. If you get [[[4]]] then the same, you want the 4\. You can access it with arr[index1][index2] to go a level deeper.
|
||||
If you are dealing with an array, then you need flatten it by getting the value inside of the array. This means if you have ```[[4]]``` then instead of returning ```[4]``` you need to return ```4```. If you get ```[[[4]]]``` then the same, you want the ```4```. You can access it with ```arr[index1][index2]``` to go a level deeper.
|
||||
|
||||
> _try to solve the problem now_
|
||||
|
||||
##  Hint: 3
|
||||
|
||||
You will definitely need recursion or another way to go beyond two level arrays to make the code flexible and not hard-coded to the answers needed. Have fun!
|
||||
|
||||
> _try to solve the problem now_
|
||||
|
||||
## Spoiler Alert!
|
||||
|
||||

|
||||
|
||||

|
||||
|
||||
**Solution ahead!**
|
||||
|
||||
|
Binary file not shown.
After Width: | Height: | Size: 9.2 KiB |
Reference in New Issue
Block a user