/leetcode-rust

Primary LanguageRustApache License 2.0Apache-2.0

My Leetcode Solution in Rust

NOTE: The original repository is great! Thanks the author and contributors of it!

Run cargo run {id} to initialize the template submission file of "question #id".

Run cargo test test_{id} to test the solution for "question #id".

Working in progress, to do:

  • auto generation of solution list (when 100 problems solved)

Usage

  • Remove all the solution .rs
  • Clean lib.rs file
  • Start your leetcode journey in rust by typing cargo run and then input the question id
  • To solve a problem (we should start the problem first), input solve {question_id}
  • To passby cloudflare, please cp .env.smaple .env, and set LEETCODE_COOKIE with your cookie (could be find in Firefox or Chrome console)