Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

a cli tool for leetcode.com

NotificationsYou must be signed in to change notification settings

hrdkmishra/leetcode.py

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

40 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

leetcode.py is a Python command-line tool that simplifies your LeetCode journey by providing a seamless interface to access and solve LeetCode problems effortlessly.

Features

  • Problem Fetching: LeetCode.py fetches the problem details directly fromleetcodeDb.json LeetCode's official API, allowing you to access all the necessary information about a problem.

  • Code Snippet Retrieval: With LeetCode.py, you can easily retrieve code snippets for a specific problem.

  • Code Editing: You can modify and edit the code directly within the terminal, saving you the hassle of switching between multiple applications.

  • ASCII Art: LeetCode.py provides a beautiful ASCII art for each problem, making your coding experience more enjoyable.

  • Language Support: LeetCode.py supportsonlyPython all languages except Python2.

Installation

git clone https://github.com/hrdkmishra/leetcode.py.gitcd leetcode.pypython3 -m venv venvsource venv/bin/activatepip install -r requirements.txt

Usage

note:lc.py --lib for fixing python-leetcode lib issue

First you need to enter your leetcode session and crsf token

python lc.py

to fetch the problem

python lc.py -q/--question <question_number>

img_1.png

to fetch problems in range (might not work always)

python lc.py -q/--question <question_number>:<question_number>

to solve the problem

python lc.py -s/--solve <question_number>

img.png

to test the code

python lc.py -t/--test code_editor/filename

to submit the code

python lc.py -u/--submit code_editor/filename

Features to be added

  1. code submission
  2. testing the user code
  3. code submission status
  4. code submission result
  5. code submission result details
  6. -h/--help
  7. color theme
  8. fixed python-leetcode lib issue
  9. add support for other languages except python2

Releases

No releases published

Packages

No packages published

[8]ページ先頭

©2009-2025 Movatter.jp