CoolFace
Datasetpublic

kaysss/leetcode-problem-solutions

LeetCode Solution Dataset This dataset contains community-contributed LeetCode solutions scraped from public discussions and solution pages, enriched with metadata such as vote counts, author info, tags, and full code content. The goal is to make high-quality, peer-reviewed coding solutions programmatically accessible for research, analysis, educational use, or developer tooling. Column Descriptions Column Name Type Description question_slug string The… See the full description on the dataset page: https://huggingface.co/datasets/kaysss/leetcode-problem-solutions.

sourceHugging Facemitupdated 1y agoView on Hugging Face
9likes5.3kdownloads
Dataset Card

LeetCode Solution Dataset

This dataset contains community-contributed LeetCode solutions scraped from public discussions and solution pages, enriched with metadata such as vote counts, author info, tags, and full code content. The goal is to make high-quality, peer-reviewed coding solutions programmatically accessible for research, analysis, educational use, or developer tooling.

Column Descriptions

Column NameTypeDescription
question_slugstringThe unique slug of the LeetCode question
titlestringTitle of the submitted solution
slugstringURL-safe identifier for the solution (can be used to reconstruct URL)
summarystringShort description or intro snippet of the solution
authorstringUsername of the contributor
certificationstringLeetCode’s certification level for the author
created_attimestampWhen the solution was originally posted
updated_attimestampWhen the solution was last modified
hit_countintNumber of views the solution has received
has_videobooleanWhether the solution includes a video explanation
contentstringThe full markdown content including code blocks
upvotesintTotal number of upvotes
downvotesintTotal number of downvotes
tagslist[str]List of tags (e.g. algorithm type, difficulty, company, etc.)
commentsintNumber of top-level comments on the solution

question_slug: Construct the link this way: "https://leetcode.com/problems/{question_slug}/description/"

This dataset is part of a broader collection of LeetCode-related resources. It complements: - [LeetCode Problem Detailed](https://huggingface.co/datasets/kaysss/leetcode-problem-detailed) – includes full problem descriptions, metadata, and statistics for each LeetCode question. - [LeetCode Problem Set](https://huggingface.co/datasets/kaysss/leetcode-problem-set) – a lightweight list of problems with slugs, titles, difficulty levels, and basic stats (without descriptions or solutions). Note: New questions and solutions are added weekly. If you'd like updates or more in-depth coverage for specific problems, feel free to reach out! The scraper used to collect this dataset is available here: timetooth/leetcode_scraper. Drop a ⭐ if you find it useful!