Welcome to the Codeforces Solutions Repository! This is a place for people to share their solutions to Codeforces problems.
If you would like to contribute your solution to a Codeforces problem, please follow these guidelines:
-
Make sure you have a GitHub account. If you don't have one, you can sign up for one here.
-
Fork the repository by clicking on the "Fork" button in the top right corner of the repository page. This will create a copy of the repository in your own GitHub account.
-
Clone the repository to your local machine using the following command:
git clone https://github.com/YOUR_USERNAME/Codeforces-Solutions.git
- Create a new branch for your changes using the following command:
git checkout -b YOUR_BRANCH_NAME
-
Open "MAIN" Folder. Then create a new folder (IF IT DOES NOT EXIST BEFORE) for each problem that you want to contribute a solution to. The folder should be named using the Codeforces problem ID (e.g. 50A, 1774H, etc.). (Please see other submissions for reference)
-
Make sure your solution is correct before submitting it. Test your solution against the provided test cases to ensure that it is correct.
-
Include a README file inside each folder. The README should contain a brief description of the problem and your solution. You can also include any additional notes or thoughts about the problem or your solution. (OPTIONAL STEP)
-
Use proper code formatting when including your solution in the README file. You can use markdown syntax to format your code blocks. (OPTIONAL STEP)
-
Commit your changes using the following commands:
git add .
git commit -m "Add solution to Codeforces problem ID"
- Push your changes to your fork of the repository using the following command:
git push origin YOUR_BRANCH_NAME
- Create a pull request by going to the repository page on your GitHub account and clicking on the "Compare & pull request" button. Make sure to include a detailed description of your changes and a reference to the Codeforces problem that your solution is for.
We appreciate any and all contributions to this repository. Thank you for helping to make it a valuable resource for the community!
Please note that the solutions provided in this repository are for reference only. They are not intended to be used as a cheat sheet or to replace learning and understanding the concepts behind the problems. It is important to understand the problems and come up with your own solutions.