String Week Challenge - Day 3

String Week Challenge - Day 3

Give it Some Space


2 min read

Hey, hey, here we are again! Today continues week 1 of my daily challenges in October. Welcome back!

⏰ Need to do some catching up?

If this is the first challenge you're seeing, welcome! My challenges build on each other throughout the week, starting on Saturday and building towards a final solution on Friday. Check out the challenges for Day 1 and Day 2 then come on back.

⭐ String Week

This week our challenges all deal with Strings! As one of JavaScript's primitive data structures, Strings are critical to understand and manipulate. Feel free to use JavaScript's built-in String methods.

🏆 The Challenge - Day 3

This week we will be discovering hidden messages by manipulating a given string. Your solutions should account for any non-empty string. On Friday we'll combine our functions to decode a message.

Yesterday you should have come up with a few specific characters that we'll need today. Let's refer to those as our key characters.

We need to create a function that will replace any instances of any of the key characters in a given string with an empty space (' '). See below for an example with an example set of key characters.

Remember to keep your code somewhere safe, as you'll need it to decrypt this week's message!

example key characters -> 'A','_','K','E','Y','!'

// implement key replacement function
' you could think this is hard to read before replacing the key characters'

You didn't think I'd just give you the key for the week and let you skip Day 2, did you?

🕵️ Thank You for playing along!

Before you head off to play with some string, I want to take a moment to thank those who have commented on the blog posts, shared likes, or tweeted about the daily challenges. It's been a huge joy for my deeply weird self to just create these ridiculous tasks, but knowing that even a few others are enjoying them means so much!

Please feel free to tag my @huntoberTweets or @blawblawlaw accounts with any comments or clues about the challenges. You can also share your solutions, but give people a spoiler warning!

Wait, What's Huntober?

Leon Noel's 100Devs are spending October preparing for the job hunt. Anyone who has already broken into a tech career knows that the application and interview process can be grueling! The current cohort has progressed this year all the way from basic HTML files to hosted full-stack applications with authentication and databases.

This month they'll continue to build, but will also work on data structures & algorithms, networking and interview skills, and solving code challenges.