Solution to the 10 Days of Javascript - Day 2: Loops in Hackerrank in NodeJS
Solutions
-
- This solution loops over the string with a traditional C-style loop as Javascript Strings do not natively provide the
forEachsemantic
- This solution loops over the string with a traditional C-style loop as Javascript Strings do not natively provide the
-
- This solution loops also over the string with the forEach semantic as it gets transformed into an array of chars first by the
split('')statement: this in fact tokenizes the string into an array which in fact supports theforEachsemantic
- This solution loops also over the string with the forEach semantic as it gets transformed into an array of chars first by the