Showing Post From Algorithms
Solving a Common Interview Question: the Two Sum Algorithm in JavaScript
Imagine you’re at a lively party, and everyone is carrying a specific number on their back. The host announces a game – find two people whose numbers add up to the magic number, and you win a prize!
Read moreUnveiling the Fascination of the Collatz Conjecture: Exploring Sequence Creation with JavaScript
The Collatz Conjecture, also known as the 3x+1 problem, is a fascinating mathematical puzzle that has intrigued mathematicians for decades. It has sparked publications with titles such as The Simplest Math Problem Could Be Unsolvable, or The Simple Math Problem We Still Can’t Solve because it is, indeed, rather simple-looking.
Read moreDefang an IP Address with JavaScript
I was asked this question long ago. At first, I was stumped. Not because the question is tricky, but because my brain shuts down when multiple people are stairing at the back of my head while I’m standing in front of a white board.
Read moreThree Common Sorting Algorithms with JavaScript
In this article, we’ll learn about three common sorting algorithms: bubble sort, selection sort, and merge sort. We’ll explore what they’re useful for, as well as how to implement them in JavaScript.
Read moreA Look At The Fibonacci Sequence: A Recursive and Iterative Solution
In mathematics, Fibonacci numbers form a sequence. The sequence commonly starts at 0 and 1. To get the next digit in the sequence, you simply add the previous two numbers together.
Read moreWhy Interviewers Still ask ‘FizzBuzz’ in 2022
This problem has been around for such a long time. Anyone who has been writing code for even a little while has probably come across it.
Read more