Skip to content

ku113p/go-leetcode

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

LeetCode Solutions in Go

This repository contains solutions to various LeetCode problems implemented in Go. Each problem is organized into its own directory under the exercises/ folder, with separate files for the solution and its corresponding tests.

How to Run

  1. Clone the repository:

    git clone https://github.com/august346/leetcode-go.git
    cd leetcode-go
  2. Install dependencies:

    go mod tidy
  3. Run a specific test:

    go test ./exercises/ex926
  4. Run all tests:

    go test ./...

Utilities

The utils/ folder contains helper functions:

  • InTime: Ensures a test completes within a specified duration.
  • ReadStringFromFile: Reads the content of a file as a string.

Example Problems

Problem 926: Flip String to Monotone Increasing

Problem 904: Fruit Into Baskets

Problem 838: Push Dominoes

Problem 153: Find Minimum in Rotated Sorted Array

Problem 1560: Most Visited Sector in a Circular Track

License

This project is licensed under the MIT License. See the LICENSE file for details.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages