Skip to main content

All Questions

3 votes
1 answer
341 views

Algorithm Challenge: Fuzzy Search

I recently took part in an algorithm challenge to create a Fuzzy search with the following criteria: Given a set array, create a function that receives one argument and returns a new array containing ...
James Ward-Sinclair's user avatar
3 votes
2 answers
3k views

Find all occurrences of all permutations of a shorter string within a longer string

Input is two strings, the first string being the long string and the second smaller string being the permuted string. The output should return the starting indices of all occurrences as well as the ...
se77en's user avatar
  • 85
1 vote
1 answer
124 views

Searching a string with text search

say that: var stringToTest = "Hello i am walking" And var searchText = "Hello walking" I have the following ...
Marc Rasmussen's user avatar
5 votes
1 answer
2k views

My attempt at a weighted search in JavaScript

I tried to make a weighted search function in JavaScript. I've been improving my JS lately but still not sure about some best practices, wondering if there's any improvements I could make, or if I've ...
Chao's user avatar
  • 205
5 votes
7 answers
12k views

Efficient Binary Search

My implementation: ...
Oliver Morgan's user avatar
40 votes
5 answers
7k views

JavaScript binary search

I wrote an implementation of binary search in JavaScript earlier for kicks, but I noticed my version was significantly different than those found on Google. Here is an example of binary search I found ...
Reid's user avatar
  • 503