DEV Community

Cover image for #10daysofcodechallenge by Ingressive for Good (#Day 10)
Dennar David
Dennar David

Posted on

#10daysofcodechallenge by Ingressive for Good (#Day 10)

I made it to the end of a 10-day coding challenge organized by Ingressive for Good and I'll be sharing my thoughts on Day 5 of the challenge.

Let me briefly describe how the challenge works before I share my experience with you. From September 21 through October 30, 2022, the challenge is to solve one common algorithm problem every day for ten days.

Today's algorithm problem was “Valid Number." It is the 65th algorithm challenge on "Leetcode.com".

The work for today was not particularly difficult; it included providing a string into a function, which would determine whether the string is a number or not and return true or false accordingly. For this, I first used the isNaN JavaScript function to determine whether the input was a number or not before checking for extreme instances like infinity. I had to adjust the code because it had not worked the first time, the result was still the same.

This task was completed in javaScript, took 112 milliseconds to execute, and consumed 44.2MB of memory.

I'd want to take this time to thank ingressive for Good for hosting such incredible challenges. I appreciate the fact that you forced me to explore places I never would have thought to go.

Top comments (0)