A repository to collect the solutions to all Competitive Programming problems (along with the competition info) across platforms and languages, only to be used as reference/practice. Main objective of this beginner-freindly repo is to help beginners to collaborate, to get acquainted with the processes of opensource, and enjoy Hacktoberfest. Broader goal is to create a dataset of programming problems across languages to be used with LLMs.
Example of one use case of a such dataset could be to optimize existing code with prompting strategy -
You are a helpful assistant. Given an inefficient implementation of bubble sort, optimize the implementation.
Inefficient Implementation:
def bubble_sort(arr):
n = len(arr)
for i in range(n):
for j in range(0, n-i-1):
if arr[j] > arr[j+1]:
arr[j], arr[j+1] = arr[j+1], arr[j]
return arr
Efficient Implementation:
def optimized_bubble_sort(arr):
n = len(arr)
for i in range(n):
swapped = False
for j in range(0, n-i-1):
if arr[j] > arr[j+1]:
arr[j], arr[j+1] = arr[j+1], arr[j]
swapped = True
if not swapped:
break
return arr
Happy Hacktoberfest! I hope that you find this project interesting and that some issues offer a good learning experience! Help of any kind would be greatly appreciated.
- You can check out the issues page for anything that interests you.
- Additionally, please check out contributing for some information on how you can contribute to this project.
Code scan is maintained with Codacy !!
Please 'star' this repo to help other beginners like you to find this repo and complete Hacktoberfest challenge.