Metadata-Version: 2.4
Name: kzleet
Version: 2025.7.29.0
Summary: a library with frequently updated LeetCode solutions created by the community
Author: Kevin Zhu
Author-email: kzhu2099@gmail.com
Maintainer: Kevin Zhu
Maintainer-email: kzhu2099@gmail.com
License: MIT License
        
        Copyright (c) 2025 Kevin Zhu
        
        Permission is hereby granted, free of charge, to any person obtaining a copy
        of this software and associated documentation files (the "Software"), to deal
        in the Software without restriction, including without limitation the rights
        to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
        copies of the Software, and to permit persons to whom the Software is
        furnished to do so, subject to the following conditions:
        
        The above copyright notice and this permission notice shall be included in all
        copies or substantial portions of the Software.
        
        THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
        IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
        FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
        AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
        LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
        OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
        SOFTWARE.
Project-URL: Homepage, https://github.com/kzhu2099/KZ-leet
Project-URL: Issues, https://github.com/kzhu2099/KZ-leet/issues
Classifier: Development Status :: 5 - Production/Stable
Classifier: Intended Audience :: Developers
Classifier: Intended Audience :: End Users/Desktop
Classifier: License :: OSI Approved :: MIT License
Classifier: Natural Language :: English
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3
Requires-Python: >=3.9
Description-Content-Type: text/markdown

# kzleet

- HomePage: https://github.com/kzhu2099/KZ-leet
- Issues: https://github.com/kzhu2099/KZ-leet/issues

[![PyPI Downloads](https://static.pepy.tech/badge/kzleet)](https://pepy.tech/projects/kzleet)

Author: Kevin Zhu, with code that may be from others (credit given).

This is a library with solutions of LeetCode everyday that is updated as quickly as possible. If I am unable to create a solution, it may not be there.

If you have a solution or would like to contribute a different one email me at kzhu2099@gmail.com. If I use yours, I will make sure to give credit!!

Note: dates follow the UTC date as does LeetCode.
Important: please visit the disclaimer below.

## Features

- a (hopefully) long list of (hopefully) unique LeetCode Solutions
- ability to contribute

## Installation

To install kzleet, use pip: ```pip install kzleet```.

However, many prefer to use a virtual environment.

macOS / Linux:

```sh
# make your desired directory
mkdir /path/to/your/directory
cd /path/to/your/directory

# setup the .venv (or whatever you want to name it)
pip install virtualenv
python3 -m venv .venv

# install kzleet
source .venv/bin/activate
pip install kzleet

deactivate # when you are completely done
```

Windows CMD:

```sh
# make your desired directory
mkdir C:path\to\your\directory
cd C:path\to\your\directory

# setup the .venv (or whatever you want to name it)
pip install virtualenv
python3 -m venv .venv

# install kzleet
.venv\Scripts\activate
pip install kzleet

deactivate # when you are completely done
```

## Usage

You may look at the problems by importing like so:

`from kzleet import Solution_####` where `####` is the problem number of the problem. They are also sorted by the LeetCode given difficulty in different files.

There may be multiple implementations: just add a letter after (`_A, _B`) for different ones.

Then, to see the code, simply run `print(Solution_####())`.

This works for both classes and functions, allowing you to see the full solution.

For solutions that have multiple steps, there may be an internal comment (visible within the print) with those extra helper functions.

## License

The License is an MIT License found in the LICENSE file.

## Disclaimer

This library provides personal / community solutions from LeetCode.
They are not the Editorial solutions that you find there, and are in no means as good as theirs.
This is for educational purposes to provide a different perspective on problems.
also, I will try my best to answer all problems. If I can't, I may ask AI (due to not having time) or it having a significantly improved solution. I will always write if it uses AI.
