I’ve always been curious about how extensions were made. After looking through various online resources, I thought I’d give it a go and have fun while making my very first extension.

What I had in mind was an extension I could turn on, and it would manipulate elements on the…

Here’s a problem that took me a while to figure out an optimal solution.

The First Duplicate Value.

So far, I’ve noticed some techniques that can be applied to data structure and algorithm problems.

For example, the pointer technique, to compare different elements in an array, and creating a hashmap…

When I first started learning about code, I always wondered how design patterns came about. Simply speaking, certain solutions would be repeated many times over until it was recognized as a common pattern that can be referenced.

Design patterns are templates that software engineers can use to provide themselves with…

Create a function that takes in a non-empty sorted array of integers, creates a Binary Search Tree (BST) from the integers, and returns the root of the BST.

The function should minimize the height of the BST.

Given a BST class.

We need to create the function, and the logic…

Since I’ve been getting deeper into front end development, I thought I’d share a few things I’ve found to be helpful to create optimized code.

Front end developing feels like solving a jigsaw puzzle to me and there are so many moments of confusion when writing code. There are plenty…

Create a function that takes in a Binary Search Tree (BST), it may be invalid, and returns a boolean value representing whether the BST is valid.

Each BST node has an integer value, a left child node, and a right child node.

A node is valid if it satisfies the…

There is an algorithms tournament taking place where teams of programmers compete against each other to solve problems as fast as possible. Teams compete in a round robin, where each team faces off against all other teams.

Only two teams compete against each other as a time, for each competition…

I recently created a solution for the three number sum problem in JavaScript, and now that I want to practice my Python, I thought I’d create a similar solution in Python. Let’s begin.

Create a function that takes an array and a target integer that represents the sum. …

Given two input strings, (a) and (b), return (true) if two letters in (a) can be swapped so that the result is equal to (b), otherwise return (false).

Note: swapping letters is defined as taking two indices (i) and (j), where (i) is not equal to (j), and swapping the…

Create a function that takes an array of at least three integers and returns a sorted array of the three largest integers in the input array.

Note: You cannot sort the input array

The function should return duplicate integers, if necessary. For example:

Input array -> [10, 5, 9, 10…