# LeetCode Difficulty Prediction from Solution Descriptions: Data Description

*English translation by SOTA – AI Community of the Russian original. Licensed CC BY-NC-SA 4.0, like the original. Organisers who would like this translation removed can email sota.ai.community@gmail.com.*

*Contest 3 (28 June 2025) of the Kazakhstan IOAI Team Selection Test (Отборочные на IOAI), 2025. This is the Data tab ("Dataset Description") of the Kaggle competition "TST Day3 Upsolving". Original: [kaggle.com/competitions/tst-day-3-upsolving/data](https://www.kaggle.com/competitions/tst-day-3-upsolving/data). The Data tab lists 3 files (1.75 MB): `train.csv`, `test.csv` and `sample_submission.csv`.*

## 📁 Data description

You are given three files:

---

### `train.csv`

Contains the training examples: a **text description of the logic of a Python solution** and the corresponding difficulty label of the problem.

| Column       | Description                                                        |
| ------------ | ------------------------------------------------------------------ |
| `id`         | Unique identifier of the example                                   |
| `difficulty` | Difficulty label of the problem: `easy`, `medium` or `hard`        |
| `code`       | Step-by-step text description of the solution's logic, in natural language |

📝 Example:

```csv
id,difficulty,code
123,easy,"Initialize two pointers i and j to 0. Loop over characters of the input string..."
```

---

### `test.csv`

Contains similar text descriptions of solutions, but **without difficulty labels**. It is used to generate your predictions.

| Column  | Description                                |
| ------- | ------------------------------------------ |
| `id`    | Unique identifier of the test example      |
| `code`  | Text description of the solution's logic   |

---

### `sample_submission.csv`

A template for submitting predictions. For each `id` from `test.csv` you must give the predicted difficulty label.

| Column       | Description                                      |
| ------------ | ------------------------------------------------ |
| `id`         | Matches `test.csv`                               |
| `difficulty` | Predicted label: `easy`, `medium` or `hard`      |
