Skip to content

wong2/leetcode-cli

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

89 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

leetcode-cli

npm version license Build

A cli tool to enjoy leetcode!

Great thanks to leetcode.com, an really awesome website!

What can it do?

  • A very EFFICIENT way to fight problems.
  • CACHING problems locally thus you can easily navigate & think it offline.
  • Do everything in CLI, no one even knows you are doing leetcode :p
  • GENERATING source code template for further coding.
  • Support live TEST and SUBMIT againts leetcode.com.
  • AUTO LOGIN among multiple sessions with single leetcode account.
  • Retrieve your previous SUBMISSION thus you can easily backup and manage your code.

Prerequisites

node.js (npm included) required, please follow the installation guide:

Install

From npm repo:

$ sudo npm install -g leetcode-cli

From source code:

$ git clone http://github.com/skygragon/leetcode-cli
$ cd leetcode-cli && npm install && sudo npm install -g .

Quick Start

Read help first                         $ lc help
Login with your leetcode account        $ lc user -l
Browse all problems                     $ lc list
Choose one problem                      $ lc show 1 -g -l cpp
Coding it!
Run test(s) and pray...                 $ lc test ./two-sum.cpp -t '[3,2,4]\n7'
Submit final solution!                  $ lc submit ./two-sum.cpp

There is More...

About

A cli tool to enjoy leetcode!

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • JavaScript 98.8%
  • Shell 1.2%