All Questions
7 questions
4
votes
2
answers
301
views
Maxcounters in JavaScript
I am trying to solve this question: MaxCounters.
Solving it is straightforward, but solving it fast enough is proving very difficult. How can I improve the performance of this code? At the moment it ...
3
votes
2
answers
354
views
Challenge: phone keypad to letters - return all possible strings
The challenge:
Given a mapping of digits to letters (as in a phone number), and a digit string, return all possible letters the number could represent. You can assume each valid number in the ...
3
votes
3
answers
1k
views
JavaScript Sort Stack Coding Challenge
A coding challenge to write a function sortStack that receives a stack of integers into ascending order (with largest integers on top) and returns another stack ...
3
votes
1
answer
627
views
Find a Sum of Particles in A Set of Boxes Given a Number of Rows and Columns
This is a code challenge, from Codewars, the details of the specific challenge in depth can be found here: https://www.codewars.com/kata/magnet-particules-in-boxes/javascript.
The summary of it ...
4
votes
3
answers
530
views
N-Repeated Element in Size 2N Array
The task
is taken from leetcode
In a array A of size 2N, there are N+1 unique elements, and exactly
one of these elements is repeated N times.
Return the element repeated N times.
...
2
votes
3
answers
528
views
Find non-duplicated integer in a list where every integer occurs three times except for one integer
The task
Given an array of integers where every integer occurs three times
except for one integer, which only occurs once, find and return the
non-duplicated integer.
For example, given [6, ...
6
votes
2
answers
583
views
Search and Replace (FreeCodeCamp intermediate algorithm scripting)
I completed this challenge Search and Replace and passed the tests:
Perform a search and replace on the sentence using the arguments provided and return the new sentence.
First argument is the ...