Skip to content

Latest commit

 

History

3 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 

Repository files navigation

Algorithm Practice

A small JavaScript practice repository for working through common algorithm and data structure problems.

Problems Included

  1. Two Sum

    • Find two indices whose values add up to a target.
  2. Move Zeroes

    • Move all zeroes to the end of an array while preserving the order of non zero values.
  3. Find the Second Largest Element in an Array

    • Return the second largest distinct value, or -1 when one does not exist.
  4. Contains Duplicate

    • Determine whether an array contains any repeated value.
  5. Longest Substring Without Repeating Characters

    • Find the length of the longest substring containing unique characters.
  6. Anagram Check

    • Determine whether two strings contain the same characters with the same frequencies.
  7. Remove Adjacent Duplicates

    • Repeatedly remove matching adjacent character pairs until none remain.
  8. Reverse the First K Elements of a Queue

    • Reverse only the first k elements of a queue while leaving the rest in order.

Running the Solutions

Open the AlgoPractice.js file inside an IDE like Visual Studio Code then right click run it inside your IDE's terminal. Results from the console log statements will then be printed to the Output section of your IDE.

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages